Skip to content

Commit 26b4d2a

Browse files
committed
test: rolldown
1 parent 33f0b3a commit 26b4d2a

File tree

5 files changed

+141
-80
lines changed

5 files changed

+141
-80
lines changed

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,8 @@ export interface Options {
9999
import text from './js.js?raw'
100100
import text2 from './jsx.jsx?raw'
101101
import text3 from './ts.ts?raw'
102+
103+
// Import attributes (Rolldown doesn't support this syntax)
102104
import text4 from './with.js' with { type: 'text' }
103105
```
104106

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,7 @@
8080
"esbuild": "^0.25.9",
8181
"eslint": "^9.33.0",
8282
"prettier": "^3.6.2",
83+
"rolldown": "1.0.0-beta.37",
8384
"rollup": "^4.46.2",
8485
"tsdown": "^0.14.1",
8586
"typescript": "^5.9.2",

pnpm-lock.yaml

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

tests/__snapshots__/basic.test.ts.snap

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,25 @@ console.log(ts_default, js_default, jsx_default, with_default, abc_default);
3737
"
3838
`;
3939
40+
exports[`rolldown 1`] = `
41+
"//#region tests/fixtures/ts.ts?raw
42+
var ts_default = "export const msg = \\"hello ts\\";\\n";
43+
44+
//#endregion
45+
//#region tests/fixtures/js.js?raw
46+
var js_default = "export const msg = \\"hello js\\";\\n";
47+
48+
//#endregion
49+
//#region tests/fixtures/jsx.jsx?raw
50+
var jsx_default = "export const msg = /* @__PURE__ */ React.createElement(\\"div\\", null, \\"hello jsx\\");\\n";
51+
52+
//#endregion
53+
//#region tests/fixtures/main.js
54+
console.log(ts_default, js_default, jsx_default);
55+
56+
//#endregion"
57+
`;
58+
4059
exports[`rollup 1`] = `
4160
"var text = "export const msg = \\"hello ts\\";\\n";
4261

0 commit comments

Comments
 (0)