rolldown 1.0.0-beta.3-commit.980c6f6 → 1.0.0-beta.3-commit.de6e9d2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/cli.cjs +22 -22
- package/dist/cjs/experimental-index.cjs +2 -2
- package/dist/cjs/index.cjs +2 -2
- package/dist/cjs/parallel-plugin-worker.cjs +4 -3
- package/dist/cjs/parse-ast-index.cjs +3 -56
- package/dist/esm/cli.mjs +6 -6
- package/dist/esm/experimental-index.mjs +2 -2
- package/dist/esm/index.mjs +2 -2
- package/dist/esm/parallel-plugin-worker.mjs +3 -2
- package/dist/esm/parse-ast-index.mjs +1 -53
- package/dist/shared/{binding-CFTx0Fs7.mjs → parse-ast-index-BDY-7XFT.mjs} +53 -1
- package/dist/shared/{binding-DTKqYZn-.cjs → parse-ast-index-p24sJjY3.cjs} +62 -16
- package/dist/shared/{src-C_LnoolI.cjs → src-BHgxMyK2.cjs} +71 -63
- package/dist/shared/{src-D9Vi1O6L.mjs → src-HKRB5bWZ.mjs} +39 -31
- package/dist/types/binding.d.ts +2 -2
- package/dist/types/options/normalized-output-options.d.ts +23 -18
- package/dist/types/parse-ast-index.d.ts +3 -2
- package/dist/types/plugin/bindingify-plugin.d.ts +3 -2
- package/dist/types/plugin/plugin-context.d.ts +3 -5
- package/dist/types/utils/bindingify-input-options.d.ts +1 -1
- package/package.json +18 -18
package/dist/types/binding.d.ts
CHANGED
|
@@ -857,7 +857,7 @@ export type HelperMode = /**
|
|
|
857
857
|
* Example:
|
|
858
858
|
*
|
|
859
859
|
* ```js
|
|
860
|
-
* import helperName from "@
|
|
860
|
+
* import helperName from "@oxc-project/runtime/helpers/helperName";
|
|
861
861
|
* helperName(...arguments);
|
|
862
862
|
* ```
|
|
863
863
|
*/
|
|
@@ -1326,7 +1326,7 @@ export interface TransformResult {
|
|
|
1326
1326
|
* Example:
|
|
1327
1327
|
*
|
|
1328
1328
|
* ```text
|
|
1329
|
-
* { "_objectSpread": "@
|
|
1329
|
+
* { "_objectSpread": "@oxc-project/runtime/helpers/objectSpread2" }
|
|
1330
1330
|
* ```
|
|
1331
1331
|
*/
|
|
1332
1332
|
helpersUsed: Record<string, string>
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { BindingMinifyOptions, BindingNormalizedOptions } from '../binding';
|
|
2
2
|
import type { SourcemapIgnoreListOption, SourcemapPathTransformOption } from '../types/misc';
|
|
3
|
-
import type { AssetFileNamesFunction, ChunkFileNamesFunction, GlobalsFunction, OutputOptions } from './output-options';
|
|
3
|
+
import type { AddonFunction, AssetFileNamesFunction, ChunkFileNamesFunction, GlobalsFunction, OutputOptions } from './output-options';
|
|
4
|
+
import { RolldownPlugin } from '..';
|
|
4
5
|
export type InternalModuleFormat = 'es' | 'cjs' | 'iife' | 'umd' | 'app';
|
|
5
6
|
export interface NormalizedOutputOptions {
|
|
6
7
|
name: string | undefined;
|
|
@@ -16,10 +17,10 @@ export interface NormalizedOutputOptions {
|
|
|
16
17
|
cssChunkFileNames: string | ChunkFileNamesFunction;
|
|
17
18
|
inlineDynamicImports: boolean;
|
|
18
19
|
externalLiveBindings: boolean;
|
|
19
|
-
banner:
|
|
20
|
-
footer:
|
|
21
|
-
intro:
|
|
22
|
-
outro:
|
|
20
|
+
banner: AddonFunction;
|
|
21
|
+
footer: AddonFunction;
|
|
22
|
+
intro: AddonFunction;
|
|
23
|
+
outro: AddonFunction;
|
|
23
24
|
esModule: boolean | 'if-default-prop';
|
|
24
25
|
extend: boolean;
|
|
25
26
|
globals: Record<string, string> | GlobalsFunction;
|
|
@@ -30,38 +31,42 @@ export interface NormalizedOutputOptions {
|
|
|
30
31
|
minify: false | BindingMinifyOptions;
|
|
31
32
|
comments: 'none' | 'preserve-legal';
|
|
32
33
|
polyfillRequire: boolean;
|
|
34
|
+
plugins: RolldownPlugin[];
|
|
33
35
|
}
|
|
34
36
|
type UnsupportedFnRet = () => never;
|
|
35
37
|
export declare class NormalizedOutputOptionsImpl implements NormalizedOutputOptions {
|
|
36
|
-
inner
|
|
37
|
-
|
|
38
|
+
private inner;
|
|
39
|
+
private outputOptions;
|
|
40
|
+
private normalizedOutputPlugins;
|
|
41
|
+
constructor(inner: BindingNormalizedOptions, outputOptions: OutputOptions, normalizedOutputPlugins: RolldownPlugin[]);
|
|
38
42
|
get dir(): string | undefined;
|
|
39
|
-
get entryFileNames(): string |
|
|
40
|
-
get chunkFileNames(): string |
|
|
41
|
-
get assetFileNames(): string |
|
|
43
|
+
get entryFileNames(): string | ChunkFileNamesFunction;
|
|
44
|
+
get chunkFileNames(): string | ChunkFileNamesFunction;
|
|
45
|
+
get assetFileNames(): string | AssetFileNamesFunction;
|
|
42
46
|
get format(): 'es' | 'cjs' | 'app' | 'iife' | 'umd';
|
|
43
47
|
get exports(): 'default' | 'named' | 'none' | 'auto';
|
|
44
48
|
get sourcemap(): boolean | 'inline' | 'hidden';
|
|
45
|
-
get cssEntryFileNames(): string |
|
|
46
|
-
get cssChunkFileNames(): string |
|
|
49
|
+
get cssEntryFileNames(): string | ChunkFileNamesFunction;
|
|
50
|
+
get cssChunkFileNames(): string | ChunkFileNamesFunction;
|
|
47
51
|
get shimMissingExports(): boolean;
|
|
48
52
|
get name(): string | undefined;
|
|
49
53
|
get file(): string | undefined;
|
|
50
54
|
get inlineDynamicImports(): boolean;
|
|
51
55
|
get externalLiveBindings(): boolean;
|
|
52
|
-
get banner():
|
|
53
|
-
get footer():
|
|
54
|
-
get intro():
|
|
55
|
-
get outro():
|
|
56
|
+
get banner(): AddonFunction;
|
|
57
|
+
get footer(): AddonFunction;
|
|
58
|
+
get intro(): AddonFunction;
|
|
59
|
+
get outro(): AddonFunction;
|
|
56
60
|
get esModule(): boolean | 'if-default-prop';
|
|
57
61
|
get extend(): boolean;
|
|
58
|
-
get globals(): Record<string, string> |
|
|
62
|
+
get globals(): Record<string, string> | GlobalsFunction;
|
|
59
63
|
get hashCharacters(): 'base64' | 'base36' | 'hex';
|
|
60
64
|
get sourcemapDebugIds(): boolean;
|
|
61
65
|
get sourcemapIgnoreList(): UnsupportedFnRet | undefined;
|
|
62
|
-
get sourcemapPathTransform():
|
|
66
|
+
get sourcemapPathTransform(): SourcemapPathTransformOption | undefined;
|
|
63
67
|
get minify(): false | BindingMinifyOptions;
|
|
64
68
|
get comments(): 'none' | 'preserve-legal';
|
|
65
69
|
get polyfillRequire(): boolean;
|
|
70
|
+
get plugins(): RolldownPlugin[];
|
|
66
71
|
}
|
|
67
72
|
export {};
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
+
import { Program } from '@oxc-project/types';
|
|
1
2
|
import type { ParseResult, ParserOptions } from './binding';
|
|
2
|
-
export declare function parseAst(filename: string, sourceText: string, options?: ParserOptions | undefined | null):
|
|
3
|
-
export declare function parseAstAsync(filename: string, sourceText: string, options?: ParserOptions | undefined | null): Promise<
|
|
3
|
+
export declare function parseAst(filename: string, sourceText: string, options?: ParserOptions | undefined | null): Program;
|
|
4
|
+
export declare function parseAstAsync(filename: string, sourceText: string, options?: ParserOptions | undefined | null): Promise<Program>;
|
|
4
5
|
export type { ParseResult, ParserOptions };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { BindingPluginOptions } from '../binding';
|
|
2
|
-
import type { Plugin } from './index';
|
|
2
|
+
import type { Plugin, RolldownPlugin } from './index';
|
|
3
3
|
import type { OutputOptions } from '../options/output-options';
|
|
4
4
|
import { PluginContextData } from './plugin-context-data';
|
|
5
5
|
import type { LogHandler, LogLevelOption } from '../types/misc';
|
|
@@ -11,5 +11,6 @@ export interface BindingifyPluginArgs {
|
|
|
11
11
|
pluginContextData: PluginContextData;
|
|
12
12
|
onLog: LogHandler;
|
|
13
13
|
logLevel: LogLevelOption;
|
|
14
|
+
normalizedOutputPlugins: RolldownPlugin[];
|
|
14
15
|
}
|
|
15
|
-
export declare function bindingifyPlugin(plugin: Plugin, options: InputOptions, outputOptions: OutputOptions, pluginContextData: PluginContextData, onLog: LogHandler, logLevel: LogLevelOption): BindingPluginOptions;
|
|
16
|
+
export declare function bindingifyPlugin(plugin: Plugin, options: InputOptions, outputOptions: OutputOptions, pluginContextData: PluginContextData, normalizedOutputPlugins: RolldownPlugin[], onLog: LogHandler, logLevel: LogLevelOption): BindingPluginOptions;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { BindingPluginContext } from '../binding';
|
|
1
|
+
import type { BindingPluginContext, ParserOptions } from '../binding';
|
|
2
2
|
import type { CustomPluginOptions, ModuleOptions, Plugin, ResolvedId } from './index';
|
|
3
3
|
import { MinimalPluginContext } from '../plugin/minimal-plugin-context';
|
|
4
4
|
import { AssetSource } from '../utils/asset-source';
|
|
@@ -8,6 +8,7 @@ import { SYMBOL_FOR_RESOLVE_CALLER_THAT_SKIP_SELF } from '../constants/plugin-co
|
|
|
8
8
|
import { PartialNull } from '../types/utils';
|
|
9
9
|
import type { LogHandler, LogLevelOption } from '../types/misc';
|
|
10
10
|
import { OutputOptions } from '../options/output-options';
|
|
11
|
+
import { Program } from '@oxc-project/types';
|
|
11
12
|
export interface EmittedAsset {
|
|
12
13
|
type: 'asset';
|
|
13
14
|
name?: string;
|
|
@@ -48,8 +49,5 @@ export declare class PluginContext extends MinimalPluginContext {
|
|
|
48
49
|
getModuleInfo(id: string): ModuleInfo | null;
|
|
49
50
|
getModuleIds(): IterableIterator<string>;
|
|
50
51
|
addWatchFile(id: string): void;
|
|
51
|
-
|
|
52
|
-
* @deprecated This rollup API won't be supported by rolldown. Using this API will cause runtime error.
|
|
53
|
-
*/
|
|
54
|
-
parse(_input: string, _options?: any): any;
|
|
52
|
+
parse(input: string, options?: ParserOptions | undefined | null): Program;
|
|
55
53
|
}
|
|
@@ -4,4 +4,4 @@ import type { OutputOptions } from '../options/output-options';
|
|
|
4
4
|
import type { BindingInputOptions } from '../binding';
|
|
5
5
|
import { LogHandler } from '../types/misc';
|
|
6
6
|
import { LogLevelOption } from '../log/logging';
|
|
7
|
-
export declare function bindingifyInputOptions(rawPlugins: RolldownPlugin[], inputOptions: InputOptions, outputOptions: OutputOptions, onLog: LogHandler, logLevel: LogLevelOption): BindingInputOptions;
|
|
7
|
+
export declare function bindingifyInputOptions(rawPlugins: RolldownPlugin[], inputOptions: InputOptions, outputOptions: OutputOptions, normalizedOutputPlugins: RolldownPlugin[], onLog: LogHandler, logLevel: LogLevelOption): BindingInputOptions;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rolldown",
|
|
3
|
-
"version": "1.0.0-beta.3-commit.
|
|
3
|
+
"version": "1.0.0-beta.3-commit.de6e9d2",
|
|
4
4
|
"description": "Fast JavaScript/TypeScript bundler in Rust with Rollup-compatible API.",
|
|
5
5
|
"homepage": "https://rolldown.rs/",
|
|
6
6
|
"repository": {
|
|
@@ -84,15 +84,15 @@
|
|
|
84
84
|
"dtsHeader": "type MaybePromise<T> = T | Promise<T>\ntype Nullable<T> = T | null | undefined\ntype VoidNullable<T = void> = T | null | undefined | void\nexport type BindingStringOrRegex = string | RegExp\n\n"
|
|
85
85
|
},
|
|
86
86
|
"dependencies": {
|
|
87
|
-
"@oxc-project/types": "0.
|
|
87
|
+
"@oxc-project/types": "0.51.0",
|
|
88
88
|
"@valibot/to-json-schema": "1.0.0-beta.5",
|
|
89
89
|
"valibot": "1.0.0-beta.14"
|
|
90
90
|
},
|
|
91
91
|
"peerDependencies": {
|
|
92
|
-
"@
|
|
92
|
+
"@oxc-project/runtime": "0.51.0"
|
|
93
93
|
},
|
|
94
94
|
"peerDependenciesMeta": {
|
|
95
|
-
"@
|
|
95
|
+
"@oxc-project/runtime": {
|
|
96
96
|
"optional": true
|
|
97
97
|
}
|
|
98
98
|
},
|
|
@@ -121,22 +121,22 @@
|
|
|
121
121
|
"typescript": "^5.7.3",
|
|
122
122
|
"unbuild": "^3.0.0",
|
|
123
123
|
"why-is-node-running": "^3.0.0",
|
|
124
|
-
"
|
|
125
|
-
"rolldown": "
|
|
124
|
+
"rolldown": "1.0.0-beta.3-commit.de6e9d2",
|
|
125
|
+
"@rolldown/testing": "0.0.1"
|
|
126
126
|
},
|
|
127
127
|
"optionalDependencies": {
|
|
128
|
-
"@rolldown/binding-darwin-arm64": "1.0.0-beta.3-commit.
|
|
129
|
-
"@rolldown/binding-darwin-x64": "1.0.0-beta.3-commit.
|
|
130
|
-
"@rolldown/binding-freebsd-x64": "1.0.0-beta.3-commit.
|
|
131
|
-
"@rolldown/binding-linux-arm-gnueabihf": "1.0.0-beta.3-commit.
|
|
132
|
-
"@rolldown/binding-linux-arm64-
|
|
133
|
-
"@rolldown/binding-linux-x64-gnu": "1.0.0-beta.3-commit.
|
|
134
|
-
"@rolldown/binding-linux-x64-musl": "1.0.0-beta.3-commit.
|
|
135
|
-
"@rolldown/binding-
|
|
136
|
-
"@rolldown/binding-
|
|
137
|
-
"@rolldown/binding-win32-ia32-msvc": "1.0.0-beta.3-commit.
|
|
138
|
-
"@rolldown/binding-win32-
|
|
139
|
-
"@rolldown/binding-win32-
|
|
128
|
+
"@rolldown/binding-darwin-arm64": "1.0.0-beta.3-commit.de6e9d2",
|
|
129
|
+
"@rolldown/binding-darwin-x64": "1.0.0-beta.3-commit.de6e9d2",
|
|
130
|
+
"@rolldown/binding-freebsd-x64": "1.0.0-beta.3-commit.de6e9d2",
|
|
131
|
+
"@rolldown/binding-linux-arm-gnueabihf": "1.0.0-beta.3-commit.de6e9d2",
|
|
132
|
+
"@rolldown/binding-linux-arm64-musl": "1.0.0-beta.3-commit.de6e9d2",
|
|
133
|
+
"@rolldown/binding-linux-x64-gnu": "1.0.0-beta.3-commit.de6e9d2",
|
|
134
|
+
"@rolldown/binding-linux-x64-musl": "1.0.0-beta.3-commit.de6e9d2",
|
|
135
|
+
"@rolldown/binding-wasm32-wasi": "1.0.0-beta.3-commit.de6e9d2",
|
|
136
|
+
"@rolldown/binding-linux-arm64-gnu": "1.0.0-beta.3-commit.de6e9d2",
|
|
137
|
+
"@rolldown/binding-win32-ia32-msvc": "1.0.0-beta.3-commit.de6e9d2",
|
|
138
|
+
"@rolldown/binding-win32-x64-msvc": "1.0.0-beta.3-commit.de6e9d2",
|
|
139
|
+
"@rolldown/binding-win32-arm64-msvc": "1.0.0-beta.3-commit.de6e9d2"
|
|
140
140
|
},
|
|
141
141
|
"scripts": {
|
|
142
142
|
"# Scrips for binding #": "_",
|