deno_lint icon indicating copy to clipboard operation
deno_lint copied to clipboard

feat(react): add use-jsx-in-jsx

Open cdaringe opened this issue 2 years ago • 6 comments

Problem

  • no place for react rules to live yet, until the plugin system gets ironed-out/formalized

Solution

  • add in initial react rule

Discussion

I fully expect this to be rejected, but figured I'd use it as a discussion mechanism :)

image

cdaringe avatar Sep 04 '21 20:09 cdaringe

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

CLAassistant avatar Sep 04 '21 20:09 CLAassistant

@magurotuna what do you think? Maybe we should already go down the JS plugin route for this rule?

bartlomieju avatar Sep 10 '21 09:09 bartlomieju

@bartlomieju Yeah I think it would be reasonable to provide lint rules for JSX as plugins rather than as builtin. It would be best to make the plugin system ready for use as soon as possible.

magurotuna avatar Sep 10 '21 15:09 magurotuna

Currently linting my whole project in JS tools takes ~9 minutes. 🙏 Is a native or WASM/WASI plug-in mechanism is still under long term consideration?

cdaringe avatar Sep 10 '21 15:09 cdaringe

Currently linting my whole project in JS tools takes ~9 minutes. 🙏 Is a native or WASM/WASI plug-in mechanism is still under long term consideration?

At the moment no, plugins would be JS/TS; but we expect it will still be way faster, because the "heavy lifting" like parsing and scope analysis would be done in Rust.

bartlomieju avatar Sep 10 '21 15:09 bartlomieju

Gotcha, cool :)

cdaringe avatar Sep 10 '21 16:09 cdaringe

closing because stale

ry avatar Nov 22 '22 15:11 ry