Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The warning about using for...of states that regenerator-runtime is required:
iterators/generators require regenerator-runtime, which is too heavyweight for this guide to allow them. Separately, loops should be avoided in favor of array iterations.
The explanation creates the impression regenerator-runtime is essential for any code using for...of, which is no longer true, as for...of seems to be fairly widely supported.
I think it could make sense to reword the explanation to state that regenerator may be required and that imperative loops should be avoided.
The text was updated successfully, but these errors were encountered:
It’s still true if you support older browsers, which most companies do indeed have to do.
It’s fine to improve the message tho.
Updated style.js for airbnb#2428
02da660
Rephrased the message and sent PR
gpoole commentedMay 18, 2021
The warning about using for...of states that regenerator-runtime is required:
The explanation creates the impression regenerator-runtime is essential for any code using for...of, which is no longer true, as for...of seems to be fairly widely supported.
I think it could make sense to reword the explanation to state that regenerator may be required and that imperative loops should be avoided.
The text was updated successfully, but these errors were encountered: