mozilla / eslint-plugin-no-unsanitized

Custom ESLint rule to disallows unsafe innerHTML, outerHTML, insertAdjacentHTML and alike
Mozilla Public License 2.0
222 stars 33 forks source link

Upgrade to & supoport ESlint v9 (fixes #234) #239

Closed Standard8 closed 1 month ago

Standard8 commented 2 months ago

This is based on top of #238 (might need rebasing once that lands to make the diffs clear), and changes the plugin to use flat config for its ESLint configuration, and then upgrades to v9. It is backwards compatible to v8, but dropping older versions to simplify the testing matrix - as well as enabling dropping unsupported versions of node.

mozfreddyb commented 2 months ago

Please rebase :)

Standard8 commented 2 months ago

Please rebase :)

Done!

Standard8 commented 1 month ago

Wow, what a load of boilerplate you had to go through to make the tests work across different configuration. Appreciate you taking the time and making sure it works with older versions, apparently?

Yes, it should work on older version - the testing matrix tests both v8 and v9.

paulrutter commented 1 month ago

Will a new version of the plugin be released to npm for this? @mozfreddyb

mozfreddyb commented 1 month ago

Yes, I started working on it, but it looks like there's a conflict with our dependencies: I think we'll need to wait until typescript-eslint releases a version that supports eslint 9.

This is unless someone can help me figure out a way to support eslint >=9 with optional typescript and eslint <9 with full typescript support.

brettz9 commented 1 day ago

@mozfreddyb : Are you open to pegging against an alpha version? There is 8.0.0-alpha.36 currently.