React-boilerplate: [Questions] about jsx-control-statements

Created on 10 Dec 2016  路  2Comments  路  Source: react-boilerplate/react-boilerplate

anyone used
https://github.com/AlexGilleran/jsx-control-statements for control statement ?

ist work with enzime chai ?

question

Most helpful comment

This isn't a project-specific question: probably better to ask here for wider reach.

For what it's worth, I'd suggest avoiding control-flow logic in your JSX as far as possible. When you _do_ need to, it's generally preferable to use standard JS syntax (ternaries, functions, etc) to return the appropriate child.

That said, if you like really exploring the possibilities of JSX's declarative syntax, this guy is a great source of inspiration (check out the smalldots library).

All 2 comments

This isn't a project-specific question: probably better to ask here for wider reach.

For what it's worth, I'd suggest avoiding control-flow logic in your JSX as far as possible. When you _do_ need to, it's generally preferable to use standard JS syntax (ternaries, functions, etc) to return the appropriate child.

That said, if you like really exploring the possibilities of JSX's declarative syntax, this guy is a great source of inspiration (check out the smalldots library).

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

hieubq90 picture hieubq90  路  3Comments

schnubor picture schnubor  路  3Comments

smiile picture smiile  路  3Comments

loicginoux picture loicginoux  路  4Comments

fobus42 picture fobus42  路  3Comments