rolldown 1.0.0-beta.3-commit.725c566 → 1.0.0-beta.3-commit.b814905
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 +2 -2
- package/dist/cjs/experimental-index.cjs +2 -2
- package/dist/cjs/index.cjs +2 -2
- package/dist/cjs/parallel-plugin-worker.cjs +2 -2
- package/dist/cjs/parse-ast-index.cjs +1 -1
- package/dist/esm/cli.mjs +2 -2
- package/dist/esm/experimental-index.mjs +2 -2
- package/dist/esm/index.mjs +2 -2
- package/dist/esm/parallel-plugin-worker.mjs +2 -2
- package/dist/esm/parse-ast-index.mjs +1 -1
- package/dist/shared/{parse-ast-index-p24sJjY3.cjs → parse-ast-index-CYgta8XV.cjs} +15 -4
- package/dist/shared/{parse-ast-index-BDY-7XFT.mjs → parse-ast-index-xu1sp-Oh.mjs} +15 -4
- package/dist/shared/{src-BjMtmwg9.cjs → src-CMgSOUyx.cjs} +12 -8
- package/dist/shared/{src-BLGmbzkm.mjs → src-DvFoEK0x.mjs} +12 -8
- package/dist/types/binding.d.ts +1 -0
- package/dist/types/index.d.ts +2 -2
- package/dist/types/parse-ast-index.d.ts +2 -2
- package/dist/types/plugin/plugin-context.d.ts +2 -1
- package/dist/types/types/rolldown-output.d.ts +1 -0
- package/package.json +14 -14
package/dist/cjs/cli.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const require_chunk = require('../shared/chunk-qZFfknuJ.cjs');
|
|
3
|
-
const require_src = require('../shared/src-
|
|
4
|
-
const require_parse_ast_index = require('../shared/parse-ast-index-
|
|
3
|
+
const require_src = require('../shared/src-CMgSOUyx.cjs');
|
|
4
|
+
const require_parse_ast_index = require('../shared/parse-ast-index-CYgta8XV.cjs');
|
|
5
5
|
const node_process = require_chunk.__toESM(require("node:process"));
|
|
6
6
|
const node_path = require_chunk.__toESM(require("node:path"));
|
|
7
7
|
const node_fs = require_chunk.__toESM(require("node:fs"));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const require_chunk = require('../shared/chunk-qZFfknuJ.cjs');
|
|
3
|
-
const require_src = require('../shared/src-
|
|
4
|
-
const require_parse_ast_index = require('../shared/parse-ast-index-
|
|
3
|
+
const require_src = require('../shared/src-CMgSOUyx.cjs');
|
|
4
|
+
const require_parse_ast_index = require('../shared/parse-ast-index-CYgta8XV.cjs');
|
|
5
5
|
const node_url = require_chunk.__toESM(require("node:url"));
|
|
6
6
|
|
|
7
7
|
//#region src/plugin/parallel-plugin.ts
|
package/dist/cjs/index.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
const require_src = require('../shared/src-
|
|
2
|
-
require('../shared/parse-ast-index-
|
|
1
|
+
const require_src = require('../shared/src-CMgSOUyx.cjs');
|
|
2
|
+
require('../shared/parse-ast-index-CYgta8XV.cjs');
|
|
3
3
|
|
|
4
4
|
exports.VERSION = require_src.VERSION
|
|
5
5
|
exports.build = require_src.build
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const require_chunk = require('../shared/chunk-qZFfknuJ.cjs');
|
|
3
|
-
const require_src = require('../shared/src-
|
|
4
|
-
const require_parse_ast_index = require('../shared/parse-ast-index-
|
|
3
|
+
const require_src = require('../shared/src-CMgSOUyx.cjs');
|
|
4
|
+
const require_parse_ast_index = require('../shared/parse-ast-index-CYgta8XV.cjs');
|
|
5
5
|
const node_worker_threads = require_chunk.__toESM(require("node:worker_threads"));
|
|
6
6
|
|
|
7
7
|
//#region src/parallel-plugin-worker.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_parse_ast_index = require('../shared/parse-ast-index-
|
|
1
|
+
const require_parse_ast_index = require('../shared/parse-ast-index-CYgta8XV.cjs');
|
|
2
2
|
|
|
3
3
|
exports.parseAst = require_parse_ast_index.parseAst
|
|
4
4
|
exports.parseAstAsync = require_parse_ast_index.parseAstAsync
|
package/dist/esm/cli.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { colors } from "../shared/parse-ast-index-
|
|
2
|
-
import { arraify, description, getInputCliKeys, getJsonSchema, getOutputCliKeys, rolldown, validateCliOptions, version, watch } from "../shared/src-
|
|
1
|
+
import { colors } from "../shared/parse-ast-index-xu1sp-Oh.mjs";
|
|
2
|
+
import { arraify, description, getInputCliKeys, getJsonSchema, getOutputCliKeys, rolldown, validateCliOptions, version, watch } from "../shared/src-DvFoEK0x.mjs";
|
|
3
3
|
import process$1, { cwd } from "node:process";
|
|
4
4
|
import path, { sep } from "node:path";
|
|
5
5
|
import fs from "node:fs";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { import_binding } from "../shared/parse-ast-index-
|
|
2
|
-
import { BuiltinPlugin, buildImportAnalysisPlugin, composeJsPlugins, createBundler, dynamicImportVarsPlugin, handleOutputErrors, importGlobPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, normalizedStringOrRegex, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin } from "../shared/src-
|
|
1
|
+
import { import_binding } from "../shared/parse-ast-index-xu1sp-Oh.mjs";
|
|
2
|
+
import { BuiltinPlugin, buildImportAnalysisPlugin, composeJsPlugins, createBundler, dynamicImportVarsPlugin, handleOutputErrors, importGlobPlugin, jsonPlugin, loadFallbackPlugin, manifestPlugin, moduleFederationPlugin, modulePreloadPolyfillPlugin, normalizedStringOrRegex, viteResolvePlugin, wasmFallbackPlugin, wasmHelperPlugin } from "../shared/src-DvFoEK0x.mjs";
|
|
3
3
|
import { pathToFileURL } from "node:url";
|
|
4
4
|
|
|
5
5
|
//#region src/plugin/parallel-plugin.ts
|
package/dist/esm/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "../shared/parse-ast-index-
|
|
2
|
-
import { VERSION, build, defineConfig, rolldown, watch } from "../shared/src-
|
|
1
|
+
import "../shared/parse-ast-index-xu1sp-Oh.mjs";
|
|
2
|
+
import { VERSION, build, defineConfig, rolldown, watch } from "../shared/src-DvFoEK0x.mjs";
|
|
3
3
|
|
|
4
4
|
export { VERSION, build, defineConfig, rolldown, watch };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { import_binding } from "../shared/parse-ast-index-
|
|
2
|
-
import { PluginContextData, bindingifyPlugin } from "../shared/src-
|
|
1
|
+
import { import_binding } from "../shared/parse-ast-index-xu1sp-Oh.mjs";
|
|
2
|
+
import { PluginContextData, bindingifyPlugin } from "../shared/src-DvFoEK0x.mjs";
|
|
3
3
|
import { parentPort, workerData } from "node:worker_threads";
|
|
4
4
|
|
|
5
5
|
//#region src/parallel-plugin-worker.ts
|
|
@@ -625,11 +625,22 @@ function normalizeParseError(sourceText, errors) {
|
|
|
625
625
|
}
|
|
626
626
|
return error(logParseError(message));
|
|
627
627
|
}
|
|
628
|
-
|
|
629
|
-
|
|
628
|
+
const defaultParserOptions = {
|
|
629
|
+
lang: "js",
|
|
630
|
+
preserveParens: false,
|
|
631
|
+
convertSpanUtf16: true
|
|
632
|
+
};
|
|
633
|
+
function parseAst(sourceText, options, filename) {
|
|
634
|
+
return wrap((0, import_binding.parseSync)(filename ?? "file.js", sourceText, {
|
|
635
|
+
...defaultParserOptions,
|
|
636
|
+
...options
|
|
637
|
+
}), sourceText).program;
|
|
630
638
|
}
|
|
631
|
-
async function parseAstAsync(
|
|
632
|
-
return wrap(await (0, import_binding.parseAsync)(filename, sourceText,
|
|
639
|
+
async function parseAstAsync(sourceText, options, filename) {
|
|
640
|
+
return wrap(await (0, import_binding.parseAsync)(filename ?? "file.js", sourceText, {
|
|
641
|
+
...defaultParserOptions,
|
|
642
|
+
...options
|
|
643
|
+
}), sourceText).program;
|
|
633
644
|
}
|
|
634
645
|
|
|
635
646
|
//#endregion
|
|
@@ -651,11 +651,22 @@ function normalizeParseError(sourceText, errors) {
|
|
|
651
651
|
}
|
|
652
652
|
return error(logParseError(message));
|
|
653
653
|
}
|
|
654
|
-
|
|
655
|
-
|
|
654
|
+
const defaultParserOptions = {
|
|
655
|
+
lang: "js",
|
|
656
|
+
preserveParens: false,
|
|
657
|
+
convertSpanUtf16: true
|
|
658
|
+
};
|
|
659
|
+
function parseAst(sourceText, options, filename) {
|
|
660
|
+
return wrap((0, import_binding.parseSync)(filename ?? "file.js", sourceText, {
|
|
661
|
+
...defaultParserOptions,
|
|
662
|
+
...options
|
|
663
|
+
}), sourceText).program;
|
|
656
664
|
}
|
|
657
|
-
async function parseAstAsync(
|
|
658
|
-
return wrap(await (0, import_binding.parseAsync)(filename, sourceText,
|
|
665
|
+
async function parseAstAsync(sourceText, options, filename) {
|
|
666
|
+
return wrap(await (0, import_binding.parseAsync)(filename ?? "file.js", sourceText, {
|
|
667
|
+
...defaultParserOptions,
|
|
668
|
+
...options
|
|
669
|
+
}), sourceText).program;
|
|
659
670
|
}
|
|
660
671
|
|
|
661
672
|
//#endregion
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
const require_chunk = require('./chunk-qZFfknuJ.cjs');
|
|
3
|
-
const require_parse_ast_index = require('./parse-ast-index-
|
|
3
|
+
const require_parse_ast_index = require('./parse-ast-index-CYgta8XV.cjs');
|
|
4
4
|
const node_path = require_chunk.__toESM(require("node:path"));
|
|
5
5
|
const node_buffer = require_chunk.__toESM(require("node:buffer"));
|
|
6
6
|
const node_worker_threads = require_chunk.__toESM(require("node:worker_threads"));
|
|
@@ -181,8 +181,6 @@ var BuiltinPlugin = class {
|
|
|
181
181
|
constructor(name, _options) {
|
|
182
182
|
this.name = name;
|
|
183
183
|
this._options = _options;
|
|
184
|
-
this.name = name;
|
|
185
|
-
this._options = _options;
|
|
186
184
|
}
|
|
187
185
|
};
|
|
188
186
|
function modulePreloadPolyfillPlugin(config) {
|
|
@@ -487,6 +485,9 @@ function transformToRenderedModule(bindingRenderedModule) {
|
|
|
487
485
|
},
|
|
488
486
|
get renderedLength() {
|
|
489
487
|
return bindingRenderedModule.code?.length || 0;
|
|
488
|
+
},
|
|
489
|
+
get renderedExports() {
|
|
490
|
+
return bindingRenderedModule.renderedExports;
|
|
490
491
|
}
|
|
491
492
|
};
|
|
492
493
|
}
|
|
@@ -592,6 +593,10 @@ function transformToRollupOutputChunk(bindingChunk, changed) {
|
|
|
592
593
|
cache[p] = newValue;
|
|
593
594
|
changed?.updated.add(bindingChunk.fileName);
|
|
594
595
|
return true;
|
|
596
|
+
},
|
|
597
|
+
has(target, p) {
|
|
598
|
+
if (p in cache) return true;
|
|
599
|
+
return p in target;
|
|
595
600
|
}
|
|
596
601
|
});
|
|
597
602
|
}
|
|
@@ -747,6 +752,7 @@ function bindingifySideEffects(sideEffects) {
|
|
|
747
752
|
//#endregion
|
|
748
753
|
//#region src/plugin/plugin-context.ts
|
|
749
754
|
var PluginContext = class extends MinimalPluginContext {
|
|
755
|
+
getModuleInfo;
|
|
750
756
|
constructor(outputOptions, context, plugin, data, onLog, logLevel, currentLoadingModule) {
|
|
751
757
|
super(onLog, logLevel, plugin.name);
|
|
752
758
|
this.outputOptions = outputOptions;
|
|
@@ -754,6 +760,7 @@ var PluginContext = class extends MinimalPluginContext {
|
|
|
754
760
|
this.data = data;
|
|
755
761
|
this.onLog = onLog;
|
|
756
762
|
this.currentLoadingModule = currentLoadingModule;
|
|
763
|
+
this.getModuleInfo = (id) => this.data.getModuleInfo(id, context);
|
|
757
764
|
}
|
|
758
765
|
async load(options) {
|
|
759
766
|
const id = options.id;
|
|
@@ -821,9 +828,6 @@ var PluginContext = class extends MinimalPluginContext {
|
|
|
821
828
|
getFileName(referenceId) {
|
|
822
829
|
return this.context.getFileName(referenceId);
|
|
823
830
|
}
|
|
824
|
-
getModuleInfo(id) {
|
|
825
|
-
return this.data.getModuleInfo(id, this.context);
|
|
826
|
-
}
|
|
827
831
|
getModuleIds() {
|
|
828
832
|
return this.data.getModuleIds(this.context);
|
|
829
833
|
}
|
|
@@ -831,7 +835,7 @@ var PluginContext = class extends MinimalPluginContext {
|
|
|
831
835
|
this.context.addWatchFile(id);
|
|
832
836
|
}
|
|
833
837
|
parse(input, options) {
|
|
834
|
-
return require_parse_ast_index.parseAst(
|
|
838
|
+
return require_parse_ast_index.parseAst(input, options);
|
|
835
839
|
}
|
|
836
840
|
};
|
|
837
841
|
|
|
@@ -2703,7 +2707,7 @@ const watch = (input) => {
|
|
|
2703
2707
|
|
|
2704
2708
|
//#endregion
|
|
2705
2709
|
//#region package.json
|
|
2706
|
-
var version = "1.0.0-beta.3-commit.
|
|
2710
|
+
var version = "1.0.0-beta.3-commit.b814905";
|
|
2707
2711
|
var description = "Fast JavaScript/TypeScript bundler in Rust with Rollup-compatible API.";
|
|
2708
2712
|
|
|
2709
2713
|
//#endregion
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { augmentCodeLocation, colors, error, import_binding, logCycleLoading, logInputHookInOutputPlugin, logInvalidLogPosition, logMinifyWarning, logMultiplyNotifyOption, logPluginError, parseAst } from "./parse-ast-index-
|
|
1
|
+
import { augmentCodeLocation, colors, error, import_binding, logCycleLoading, logInputHookInOutputPlugin, logInvalidLogPosition, logMinifyWarning, logMultiplyNotifyOption, logPluginError, parseAst } from "./parse-ast-index-xu1sp-Oh.mjs";
|
|
2
2
|
import path from "node:path";
|
|
3
3
|
import { Buffer } from "node:buffer";
|
|
4
4
|
import { Worker } from "node:worker_threads";
|
|
@@ -179,8 +179,6 @@ var BuiltinPlugin = class {
|
|
|
179
179
|
constructor(name, _options) {
|
|
180
180
|
this.name = name;
|
|
181
181
|
this._options = _options;
|
|
182
|
-
this.name = name;
|
|
183
|
-
this._options = _options;
|
|
184
182
|
}
|
|
185
183
|
};
|
|
186
184
|
function modulePreloadPolyfillPlugin(config) {
|
|
@@ -485,6 +483,9 @@ function transformToRenderedModule(bindingRenderedModule) {
|
|
|
485
483
|
},
|
|
486
484
|
get renderedLength() {
|
|
487
485
|
return bindingRenderedModule.code?.length || 0;
|
|
486
|
+
},
|
|
487
|
+
get renderedExports() {
|
|
488
|
+
return bindingRenderedModule.renderedExports;
|
|
488
489
|
}
|
|
489
490
|
};
|
|
490
491
|
}
|
|
@@ -590,6 +591,10 @@ function transformToRollupOutputChunk(bindingChunk, changed) {
|
|
|
590
591
|
cache[p] = newValue;
|
|
591
592
|
changed?.updated.add(bindingChunk.fileName);
|
|
592
593
|
return true;
|
|
594
|
+
},
|
|
595
|
+
has(target, p) {
|
|
596
|
+
if (p in cache) return true;
|
|
597
|
+
return p in target;
|
|
593
598
|
}
|
|
594
599
|
});
|
|
595
600
|
}
|
|
@@ -745,6 +750,7 @@ function bindingifySideEffects(sideEffects) {
|
|
|
745
750
|
//#endregion
|
|
746
751
|
//#region src/plugin/plugin-context.ts
|
|
747
752
|
var PluginContext = class extends MinimalPluginContext {
|
|
753
|
+
getModuleInfo;
|
|
748
754
|
constructor(outputOptions, context, plugin, data, onLog, logLevel, currentLoadingModule) {
|
|
749
755
|
super(onLog, logLevel, plugin.name);
|
|
750
756
|
this.outputOptions = outputOptions;
|
|
@@ -752,6 +758,7 @@ var PluginContext = class extends MinimalPluginContext {
|
|
|
752
758
|
this.data = data;
|
|
753
759
|
this.onLog = onLog;
|
|
754
760
|
this.currentLoadingModule = currentLoadingModule;
|
|
761
|
+
this.getModuleInfo = (id) => this.data.getModuleInfo(id, context);
|
|
755
762
|
}
|
|
756
763
|
async load(options) {
|
|
757
764
|
const id = options.id;
|
|
@@ -819,9 +826,6 @@ var PluginContext = class extends MinimalPluginContext {
|
|
|
819
826
|
getFileName(referenceId) {
|
|
820
827
|
return this.context.getFileName(referenceId);
|
|
821
828
|
}
|
|
822
|
-
getModuleInfo(id) {
|
|
823
|
-
return this.data.getModuleInfo(id, this.context);
|
|
824
|
-
}
|
|
825
829
|
getModuleIds() {
|
|
826
830
|
return this.data.getModuleIds(this.context);
|
|
827
831
|
}
|
|
@@ -829,7 +833,7 @@ var PluginContext = class extends MinimalPluginContext {
|
|
|
829
833
|
this.context.addWatchFile(id);
|
|
830
834
|
}
|
|
831
835
|
parse(input, options) {
|
|
832
|
-
return parseAst(
|
|
836
|
+
return parseAst(input, options);
|
|
833
837
|
}
|
|
834
838
|
};
|
|
835
839
|
|
|
@@ -2701,7 +2705,7 @@ const watch = (input) => {
|
|
|
2701
2705
|
|
|
2702
2706
|
//#endregion
|
|
2703
2707
|
//#region package.json
|
|
2704
|
-
var version = "1.0.0-beta.3-commit.
|
|
2708
|
+
var version = "1.0.0-beta.3-commit.b814905";
|
|
2705
2709
|
var description = "Fast JavaScript/TypeScript bundler in Rust with Rollup-compatible API.";
|
|
2706
2710
|
|
|
2707
2711
|
//#endregion
|
package/dist/types/binding.d.ts
CHANGED
package/dist/types/index.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ import { rolldown } from './api/rolldown';
|
|
|
11
11
|
import { watch } from './api/watch';
|
|
12
12
|
import { ConfigExport } from './types/config-export';
|
|
13
13
|
import { RolldownBuild } from './api/rolldown/rolldown-build';
|
|
14
|
-
import { EmittedAsset, EmittedFile, PluginContext } from './plugin/plugin-context';
|
|
14
|
+
import { EmittedAsset, EmittedFile, GetModuleInfo, PluginContext } from './plugin/plugin-context';
|
|
15
15
|
import { TransformPluginContext } from './plugin/transform-plugin-context';
|
|
16
16
|
import { InternalModuleFormat, NormalizedOutputOptions } from './options/normalized-output-options';
|
|
17
17
|
import { PreRenderedChunk } from './binding';
|
|
@@ -26,5 +26,5 @@ import { RolldownWatcher } from './api/watch/watch-emitter';
|
|
|
26
26
|
import { build, type BuildOptions } from './api/build';
|
|
27
27
|
export { defineConfig, rolldown, watch, build };
|
|
28
28
|
export declare const VERSION: string;
|
|
29
|
-
export type { OutputAsset, OutputChunk, RolldownOptions, RolldownOutput, RolldownBuild, InputOptions, NormalizedInputOptions, OutputOptions, NormalizedOutputOptions, Plugin, RolldownPlugin, RolldownPluginOption, DefineParallelPluginResult, ConfigExport, ImportKind, InputOption, ExternalOption, ModuleFormat, ModuleType, InternalModuleFormat, LoadResult, TransformResult, ResolveIdResult, HookFilterExtension, HookFilter, StringFilter, ModuleTypeFilter, PluginContext, TransformPluginContext, ObjectHook, PreRenderedChunk, PreRenderedAsset, SourceMap, SourceDescription, PartialNull, PartialResolvedId, ResolvedId, ModuleOptions, ModuleInfo, PluginContextMeta, MinimalPluginContext, EmittedFile, EmittedAsset, CustomPluginOptions, AsyncPluginHooks, ParallelPluginHooks, FunctionPluginHooks, ExistingRawSourceMap, SourceMapInput, OutputBundle, JsxOptions, WatchOptions, RolldownWatcher, BuildOptions, RenderedChunk, LogOrStringHandler, };
|
|
29
|
+
export type { OutputAsset, OutputChunk, RolldownOptions, RolldownOutput, RolldownBuild, InputOptions, NormalizedInputOptions, OutputOptions, NormalizedOutputOptions, Plugin, RolldownPlugin, RolldownPluginOption, DefineParallelPluginResult, ConfigExport, ImportKind, InputOption, ExternalOption, ModuleFormat, ModuleType, InternalModuleFormat, LoadResult, TransformResult, ResolveIdResult, HookFilterExtension, HookFilter, StringFilter, ModuleTypeFilter, PluginContext, TransformPluginContext, ObjectHook, PreRenderedChunk, PreRenderedAsset, SourceMap, SourceDescription, PartialNull, PartialResolvedId, ResolvedId, ModuleOptions, ModuleInfo, PluginContextMeta, MinimalPluginContext, EmittedFile, EmittedAsset, CustomPluginOptions, AsyncPluginHooks, ParallelPluginHooks, FunctionPluginHooks, ExistingRawSourceMap, SourceMapInput, OutputBundle, JsxOptions, WatchOptions, RolldownWatcher, BuildOptions, RenderedChunk, LogOrStringHandler, GetModuleInfo, };
|
|
30
30
|
export type { RollupError, RollupLog, LoggingFunction, LogLevel, WarningHandlerWithDefault, } from './types/misc';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Program } from '@oxc-project/types';
|
|
2
2
|
import type { ParseResult, ParserOptions } from './binding';
|
|
3
|
-
export declare function parseAst(
|
|
4
|
-
export declare function parseAstAsync(
|
|
3
|
+
export declare function parseAst(sourceText: string, options?: ParserOptions | undefined | null, filename?: string): Program;
|
|
4
|
+
export declare function parseAstAsync(sourceText: string, options?: ParserOptions | undefined | null, filename?: string): Promise<Program>;
|
|
5
5
|
export type { ParseResult, ParserOptions };
|
|
@@ -31,12 +31,14 @@ export interface PluginContextResolveOptions {
|
|
|
31
31
|
export interface PrivatePluginContextResolveOptions extends PluginContextResolveOptions {
|
|
32
32
|
[SYMBOL_FOR_RESOLVE_CALLER_THAT_SKIP_SELF]?: symbol;
|
|
33
33
|
}
|
|
34
|
+
export type GetModuleInfo = (moduleId: string) => ModuleInfo | null;
|
|
34
35
|
export declare class PluginContext extends MinimalPluginContext {
|
|
35
36
|
private outputOptions;
|
|
36
37
|
private context;
|
|
37
38
|
private data;
|
|
38
39
|
private onLog;
|
|
39
40
|
private currentLoadingModule?;
|
|
41
|
+
getModuleInfo: GetModuleInfo;
|
|
40
42
|
constructor(outputOptions: OutputOptions, context: BindingPluginContext, plugin: Plugin, data: PluginContextData, onLog: LogHandler, logLevel: LogLevelOption, currentLoadingModule?: string | undefined);
|
|
41
43
|
load(options: {
|
|
42
44
|
id: string;
|
|
@@ -46,7 +48,6 @@ export declare class PluginContext extends MinimalPluginContext {
|
|
|
46
48
|
emitFile(file: EmittedAsset | EmittedChunk): string;
|
|
47
49
|
private getAssetFileNames;
|
|
48
50
|
getFileName(referenceId: string): string;
|
|
49
|
-
getModuleInfo(id: string): ModuleInfo | null;
|
|
50
51
|
getModuleIds(): IterableIterator<string>;
|
|
51
52
|
addWatchFile(id: string): void;
|
|
52
53
|
parse(input: string, options?: ParserOptions | undefined | null): Program;
|
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.b814905",
|
|
4
4
|
"description": "Fast JavaScript/TypeScript bundler in Rust with Rollup-compatible API.",
|
|
5
5
|
"homepage": "https://rolldown.rs/",
|
|
6
6
|
"repository": {
|
|
@@ -122,21 +122,21 @@
|
|
|
122
122
|
"unbuild": "^3.0.0",
|
|
123
123
|
"why-is-node-running": "^3.0.0",
|
|
124
124
|
"@rolldown/testing": "0.0.1",
|
|
125
|
-
"rolldown": "1.0.0-beta.3-commit.
|
|
125
|
+
"rolldown": "1.0.0-beta.3-commit.b814905"
|
|
126
126
|
},
|
|
127
127
|
"optionalDependencies": {
|
|
128
|
-
"@rolldown/binding-darwin-x64": "1.0.0-beta.3-commit.
|
|
129
|
-
"@rolldown/binding-
|
|
130
|
-
"@rolldown/binding-
|
|
131
|
-
"@rolldown/binding-linux-
|
|
132
|
-
"@rolldown/binding-linux-arm64-musl": "1.0.0-beta.3-commit.
|
|
133
|
-
"@rolldown/binding-linux-
|
|
134
|
-
"@rolldown/binding-linux-x64-
|
|
135
|
-
"@rolldown/binding-
|
|
136
|
-
"@rolldown/binding-wasm32-wasi": "1.0.0-beta.3-commit.
|
|
137
|
-
"@rolldown/binding-win32-
|
|
138
|
-
"@rolldown/binding-win32-
|
|
139
|
-
"@rolldown/binding-win32-x64-msvc": "1.0.0-beta.3-commit.
|
|
128
|
+
"@rolldown/binding-darwin-x64": "1.0.0-beta.3-commit.b814905",
|
|
129
|
+
"@rolldown/binding-linux-arm-gnueabihf": "1.0.0-beta.3-commit.b814905",
|
|
130
|
+
"@rolldown/binding-freebsd-x64": "1.0.0-beta.3-commit.b814905",
|
|
131
|
+
"@rolldown/binding-linux-arm64-gnu": "1.0.0-beta.3-commit.b814905",
|
|
132
|
+
"@rolldown/binding-linux-arm64-musl": "1.0.0-beta.3-commit.b814905",
|
|
133
|
+
"@rolldown/binding-linux-x64-gnu": "1.0.0-beta.3-commit.b814905",
|
|
134
|
+
"@rolldown/binding-linux-x64-musl": "1.0.0-beta.3-commit.b814905",
|
|
135
|
+
"@rolldown/binding-darwin-arm64": "1.0.0-beta.3-commit.b814905",
|
|
136
|
+
"@rolldown/binding-wasm32-wasi": "1.0.0-beta.3-commit.b814905",
|
|
137
|
+
"@rolldown/binding-win32-ia32-msvc": "1.0.0-beta.3-commit.b814905",
|
|
138
|
+
"@rolldown/binding-win32-arm64-msvc": "1.0.0-beta.3-commit.b814905",
|
|
139
|
+
"@rolldown/binding-win32-x64-msvc": "1.0.0-beta.3-commit.b814905"
|
|
140
140
|
},
|
|
141
141
|
"scripts": {
|
|
142
142
|
"# Scrips for binding #": "_",
|