Skip to content

Commit 5e5c9e2

Browse files
committed
fix: support Rolldown 1.0 RC
1 parent 3115f17 commit 5e5c9e2

3 files changed

Lines changed: 90 additions & 97 deletions

File tree

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@
3232
"packageManager": "pnpm@10.28.1",
3333
"devDependencies": {
3434
"@types/node": "^22.2.0",
35-
"rolldown": "canary",
35+
"rolldown": "^1.0.0-rc.1",
3636
"typescript": "^5.5.4",
3737
"vitest": "^4.0.0"
3838
},

pnpm-lock.yaml

Lines changed: 78 additions & 88 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/index.ts

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,17 @@ export default function (opts: NodePolyfillsOptions = {}): Plugin {
2525
options(options) {
2626
return {
2727
...options,
28-
inject: {
29-
process: PREFIX + 'process',
30-
Buffer: [PREFIX + 'buffer', 'Buffer'],
31-
global: PREFIX + 'global',
32-
__filename: FILENAME_PATH,
33-
__dirname: DIRNAME_PATH,
34-
...options.inject
35-
}
28+
transform: {
29+
...options.transform,
30+
inject: {
31+
process: PREFIX + 'process',
32+
Buffer: [PREFIX + 'buffer', 'Buffer'],
33+
global: PREFIX + 'global',
34+
__filename: FILENAME_PATH,
35+
__dirname: DIRNAME_PATH,
36+
...options.transform?.inject,
37+
},
38+
},
3639
}
3740
},
3841
resolveId(importee: string, importer?: string) {

0 commit comments

Comments
 (0)