remove: better usage of oxc ecosystem#926
Conversation
PR SummaryMedium Risk Overview Parsing and API links: JSX codegen: Tests: Adds broad Reviewed by Cursor Bugbot for commit 9b7806f. Bugbot is set up for automated code reviews on this repo. Configure here. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #926 +/- ##
==========================================
- Coverage 84.89% 77.24% -7.66%
==========================================
Files 193 127 -66
Lines 17512 9475 -8037
Branches 1551 700 -851
==========================================
- Hits 14867 7319 -7548
+ Misses 2639 2150 -489
Partials 6 6 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
| Metric | Base | Head | Diff |
|---|---|---|---|
| Elapsed time | 1.37 s | 880.00 ms | -490.00 ms (-35.77%) |
| User CPU time | 2.83 s | 1.90 s | -930.00 ms (-32.86%) |
| System CPU time | 320.00 ms | 230.00 ms | -90.00 ms (-28.13%) |
| Peak resident memory | 351.20 MB | 336.84 MB | -14.36 MB (-4.09%) |
legacy-html Generator
Performance
| Metric | Base | Head | Diff |
|---|---|---|---|
| Elapsed time | 20.14 s | 19.15 s | -990.00 ms (-4.92%) |
| User CPU time | 62.86 s | 60.00 s | -2.86 s (-4.55%) |
| System CPU time | 2.64 s | 2.57 s | -70.00 ms (-2.65%) |
| Peak resident memory | 2.17 GB | 2.25 GB | +78.28 MB (+3.52%) |
legacy-json Generator
Performance
| Metric | Base | Head | Diff |
|---|---|---|---|
| Elapsed time | 9.46 s | 10.09 s | +630.00 ms (+6.66%) |
| User CPU time | 27.76 s | 27.26 s | -500.00 ms (-1.80%) |
| System CPU time | 1.87 s | 1.95 s | +80.00 ms (+4.28%) |
| Peak resident memory | 1.58 GB | 1.68 GB | +100.96 MB (+6.24%) |
llms-txt Generator
Performance
| Metric | Base | Head | Diff |
|---|---|---|---|
| Elapsed time | 6.87 s | 9.01 s | +2.14 s (+31.15%) |
| User CPU time | 19.03 s | 25.08 s | +6.05 s (+31.79%) |
| System CPU time | 1.53 s | 1.80 s | +270.00 ms (+17.65%) |
| Peak resident memory | 1.71 GB | 1.58 GB | -130.01 MB (-7.44%) |
orama-db Generator
Performance
| Metric | Base | Head | Diff |
|---|---|---|---|
| Elapsed time | 6.63 s | 9.15 s | +2.52 s (+38.01%) |
| User CPU time | 19.23 s | 24.25 s | +5.02 s (+26.11%) |
| System CPU time | 1.66 s | 1.92 s | +260.00 ms (+15.66%) |
| Peak resident memory | 1.82 GB | 1.68 GB | -148.95 MB (-7.98%) |
web Generator
Output size
| File | Base | Head | Diff |
|-|-|-|-|
| all.html | 21.28 MB | 21.28 MB | -202.00 B (-0.00%) |
Performance
| Metric | Base | Head | Diff |
|---|---|---|---|
| Elapsed time | 79.07 s | 72.13 s | -6.94 s (-8.78%) |
| User CPU time | 166.52 s | 148.69 s | -17.83 s (-10.71%) |
| System CPU time | 4.79 s | 4.45 s | -340.00 ms (-7.10%) |
| Peak resident memory | 5.56 GB | 5.77 GB | +216.49 MB (+3.80%) |
e309de1 to
6f6ba88
Compare
This reverts commit 6f6ba88.
|
Hi. I'm one of Oxc's core team. I'd recommend using |
|
thanks @overlookmotel for your input there. and any more info around |
| sourceText | ||
| ) { | ||
| if (!exports.identifiers.includes(node.id.name)) { | ||
| // Function isn't exported, not relevant to us |
There was a problem hiding this comment.
Why are all these comments removed?
There was a problem hiding this comment.
like mister bean said "magics" I mean it's an error from my side while working on that
| import { jsx, toJs } from 'estree-util-to-js'; | ||
| import { print } from 'esrap'; | ||
| import tsx from 'esrap/languages/tsx'; |
There was a problem hiding this comment.
Does estree-util-to-js not support oxc?
There was a problem hiding this comment.
If we change that, it should be a separate discussion, IMO
There was a problem hiding this comment.
yeah is it but esrap is much more smaller 183,9 ko and estree-util-to-js is 529,6 ko. and it's look little bit quicker (based on tests I didn't get why benchmark GH comment is updated)
| const { code } = print( | ||
| content, | ||
| tsx({ | ||
| // SUPER IMPORTANT: use double instead roldown will fail on certain unicode |
There was a problem hiding this comment.
yeah if you didn't set this option it's will break. for certain unicode
[PARSE_ERROR] Invalid Unicode escape sequence
- in \0virtual:crypto.jsx at 44577..44578
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 3319391. Configure here.
avivkeller
left a comment
There was a problem hiding this comment.
We can't rely on oxc until they provide native bindings for all the platforms in Node.js's CI, or we don't build the docs on those platforms.

Description
main: +-200ms for api-link test
with changes: 150ms api-link for test
So there aren't perf gap we just win on the amount of dependency
also since
oxc-parserdidn't havelocI had to write small code that do same job once oxc-parser will have loc we will be able to come backalso use
esraprecommend by oxc https://oxc.rs/docs/guide/usage/parser.html#print which is lighterValidation
test should pass
Related Issues
NA
Check List
node --run testand all tests passed.node --run format&node --run lint.