Skip to content

Conversation

overlookmotel
Copy link
Member

@overlookmotel overlookmotel commented Oct 9, 2025

Draft blog post announcing Oxlint JS plugins.

It's not quite as polished as I'd like it to be, but we need to get it out, and I've run out of time, having prioritised getting the selectors DSL implemented.

The benchmarks are a bit weird, for 2 reasons:

  1. In other rough benchmarks, we've seen JS plugins have a much higher cost. These benchmark numbers were originally from Cam's laptop, and I've replicated the result on my MacBook Air M3. But I ran into the same problem I had before that adding a JS plugin actually improves performance. This is clearly a nonsense - that's a side effect of either reduced file system contention, or some oddity of thread scheduling on M-series chips with efficiency cores. But getting to the bottom of that would take days, or maybe even weeks.

  2. Oxlint is coming out at only 10x faster than ESLint. I think we'd expect a lot more than that. As a guess, it might be that ESLint in this case is not generating any errors, whereas Oxlint generates ~200 diagnostics. Printing diagnostics is really slow.

I actually don't think it matters that much if they're not super-scientific. Obviously, the performance is going to vary a lot depending on how many plugins, and how complex they are.

The benchmarks do still represent the thrust of the truth:

  1. JS plugins are much faster than you'd expect.
  2. Oxlint is way faster than ESLint, even with JS plugins in the mix.

In my opinion, I don't think it's going to be possible to get a more solid benchmark in a reasonable amount of time, so our choices are: either go with them or, if we're uncomfortable with how unscientific it is, just remove them.

The main point of the blog post is the feature, not the performance.

Copy link
Member Author

overlookmotel commented Oct 9, 2025

This stack of pull requests is managed by Graphite. Learn more about stacking.

@overlookmotel overlookmotel marked this pull request as ready for review October 9, 2025 03:02
Base automatically changed from 10-08-docs_linter_add_js_plugins_documentation to main October 9, 2025 07:34
@overlookmotel overlookmotel force-pushed the 10-09-oxlint_js_plugins_blog_post branch from 91c25a7 to ae91723 Compare October 9, 2025 07:36
Copy link

netlify bot commented Oct 9, 2025

Deploy Preview for oxc-project ready!

Name Link
🔨 Latest commit 346ab85
🔍 Latest deploy log https://app.netlify.com/projects/oxc-project/deploys/68e77296cb123c000824ebf6
😎 Deploy Preview https://deploy-preview-542--oxc-project.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@overlookmotel overlookmotel force-pushed the 10-09-oxlint_js_plugins_blog_post branch from ae91723 to b860331 Compare October 9, 2025 07:42
@overlookmotel overlookmotel force-pushed the 10-09-oxlint_js_plugins_blog_post branch from b860331 to 346ab85 Compare October 9, 2025 08:30
Run Oxlint:

```sh
pnpm oxlint
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this be pnpx? or should it be clear that oxlint is a script in the package.json?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pnpm dlx actually

Copy link
Contributor

@camc314 camc314 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit: :shipit:

to inform design for Oxlint support for custom JS plugins. Today, we are pleased to announce the result of many months
of research, prototyping, and finally building:

**Oxlint supports plugins written in JS!**
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should we also add the eslint compat here in the headline?

- Performance is good, but it's going to get _way_ better - we have many optimizations in the pipeline.

The most commonly-used APIs for code-checking rules [are implemented](#features), so many existing ESLint rules will already work.
But token-related APIs are absent, so stylistic (formatting) rules will not.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mention antfu config here briefly & plans?

Copy link
Member

@TheAlexLichter TheAlexLichter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

small remarks only

@camc314
Copy link
Contributor

camc314 commented Oct 9, 2025

small remarks only

we're going to fix these in a follow up so the blog post is there and published in time for the talk

@camc314 camc314 merged commit 3a91007 into main Oct 9, 2025
6 checks passed
@camc314 camc314 deleted the 10-09-oxlint_js_plugins_blog_post branch October 9, 2025 09:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants