Reactiflux

R

Reactiflux

The largest chat community for React professionals

Join

react-forum

help-js

help-threads-react

.blitzmachine – 17-08 Sep 9

```js class WhatEverYouCanImagine { constructor() { window.addEventListener("resize", this.onWindowResize); }...

.blitzmachine – 18-43 Aug 27

Is this a good pattern or not, in JS specially, to wrap my custom logic around an object, before I decide how to initialize /& return it?
No description

✅ – .blitzmachine – 16-54 Aug 16

Is it normal that I stuck on variable/function name longer than the actual code itself?
Solution:
Adding more coments (especially function doc comments) can help give you peace of mind if you think there's important quirks to your functions that aren't fully captured by the name
Message Not Public
Sign In & Join Server To View

snowberb – 13-45 Mar 27

I have an array of objects which consists of information about the properties of a building. This array can have just 4 or more than 500 properties depending on the apartment complex. Based on this array, and the information of each property, I have to render some inputs which are Block, Stair, Floor and Door. In that said order, I have to populate the next input only with the matching data based on what the user selected. For example, if the Block 3 only has stairs E, F, G, only these options are going to show up in the Stairs input. And its the same for the next ones, if the Stair E has only floors 5 and 6, only these will show up on the Floor input. The problem im facing with my code now, is that Blocks, Stairs and Floors are optional and may not be available. I do not know how I can rearrange my code so that if the property "block" or "stair" or "floor" is missing, the filter automatically works with the next available piece of information....