-
Notifications
You must be signed in to change notification settings - Fork 45.9k
New issue
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
Bug: "Unsafe assignment to innerHTML" warning from Mozilla addons linter #21993
Comments
This issue has been automatically marked as stale. If this issue is still affecting you, please leave any comment (for example, "bump"), and we'll keep it open. We are sorry that we haven't been able to prioritize it yet. If you have any new additional information, please include it with your comment! |
Hopefully this will eventually receive a setting or something, it's still an issue. |
This issue has been automatically marked as stale. If this issue is still affecting you, please leave any comment (for example, "bump"), and we'll keep it open. We are sorry that we haven't been able to prioritize it yet. If you have any new additional information, please include it with your comment! |
Please reopen this as it is not sorted out yet |
Can it be sorted out? Pretty sure |
Our Browser Extension addon seems to be stuck in review with Mozilla, and their submission service is feeding back (what appear to be ESLint warnings), saying "Unsafe assignment to innerHTML."
I can recreate the warnings by running the Mozilla addons-linter on our extension's dist files and removing
react-dom
prevents the warnings, but then of course there is noReactDOM.render
func to render the react app onto the page.Is there any alternative to
react-dom
without moving away from react completely, or a way to prevent the assignment of.innerHTML
from being in the dist files of a react app?React version: 16.9.0
Steps To Reproduce
addons-linter
npm package to lint the dist files.Link to code example:
react/packages/react-dom/src/client/setInnerHTML.js
Line 63 in cae6350
System:
OS: macOS 10.15.7
Binaries:
Node: 12.2.0 - ~/.nvm/versions/node/v12.2.0/bin/node
npm: 7.5.2 - ~/.nvm/versions/node/v12.2.0/bin/npm
npmPackages:
@babel/core: ^7.5.5 => 7.5.5
@babel/preset-env: ^7.5.5 => 7.5.5
@babel/preset-react: ^7.0.0 => 7.0.0
babel-jest: ^24.9.0 => 24.9.0
babel-loader: ^8.0.6 => 8.0.6
babel-plugin-emotion: ^10.0.19 => 10.0.19
jest: ^24.9.0 => 24.9.0
webpack: ^4.39.2 => 4.39.2
The current behavior
It is not possible to build Web Extensions with react which do not trigger the "Unsafe assignment to innerHTML" warnings from the Mozilla addons linter.
The expected behavior
It is possible to build Web Extensions with react which do not trigger the "Unsafe assignment to innerHTML" warnings from the Mozilla addons linter.
The text was updated successfully, but these errors were encountered: