4 ms·
I don't understand what you're trying to demonstrate with your example. Your TS(?) example is needlessly complicated, and syntactically invalid. Here's a bette
by paavohtl 7y ago
I don't understand what you're trying to demonstrate with your example. Your TS(?) example is needlessly complicated, and syntactically invalid.
Here's a better TS implementation:
togglePanel = (panelToggle: bool) => this.setState({ panelToggle })
- sbr464 7y agoI agree, it wasn't a good example. More was (attempting) to make a point when inside a complex file, what I've seen. With long interface names mixed in with long variable names, contributing to larger files sizes than necessary. It varies depending on project/company. It's lowercase `boolean`.