un-ts / eslint-plugin-import-x

`eslint-plugin-import-x` is a fork of `eslint-plugin-import` that aims to provide a more performant and more lightweight version of the original plugin.

Home Page:https://npm.im/eslint-plugin-import-x

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

`eslint-plugin-r`?

wojtekmaj opened this issue · comments

Hey there!

I thought I would follow the same path and create a fork of eslint-plugin-react, eslint-plugin-r, shaving off unnecessary polyfills. It's nowhere near as well done, as it lacks auto-release feature for example, but if anyone's interested, here it is:

https://github.com/wojtekmaj/eslint-plugin-r

I'd definitely use this. Those polyfills need to go 😆.

I may have more definite, global solution, that doesn't require forking anything. But for the best experience, it requires Yarn.

There's an amazing project by @SukkaW that I wholeheartedly recommend:

https://github.com/wojtekmaj/yarn-plugin-nolyfill

It uses native capabilities of each package manager to replace problematic polyfills with ultralight wrappers using native functions.

It works wonders, but I wanted it to work transparently, with minimal friction.

And I built a Yarn plugins that replaces these dependency during resolution:

https://github.com/wojtekmaj/yarn-plugin-nolyfill

I also toyed with the idea of bundling these eslint plugins with esbuild in my config package because install time is my primary concern. esbuild itself may have means to eliminate useless polyfills too.

As far as I can tell, eslint does not offer a documented way to load a plugin from a local directory, e.g. every plugin must also be a npm module, but I'm sure there would be workarounds available.

As far as I can tell, eslint does not offer a documented way to load a plugin from a local directory, e.g. every plugin must also be a npm module, but I'm sure there would be workarounds available.

@silverwind This should be easy to workaround with npm install -D eslint-plugin-xxx@file:local/path

Found an interesting replacement: eslint-react/eslint-react

Did you archive https://github.com/wojtekmaj/eslint-plugin-r due to the replacement plugin?

It seems that in case of eslint-plugin-react, nolyfill does the job well. So unless we can make it equally automated as eslint-plugin-i, I don't think it's worth maintaining. Fully automated though? Yes please!

OK, I'll close this issue then.