@rspack/binding 1.4.0-beta.1 → 1.4.0
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/README.md +1 -1
- package/binding.d.ts +19 -1
- package/binding.js +3 -13
- package/package.json +11 -11
package/README.md
CHANGED
package/binding.d.ts
CHANGED
|
@@ -41,7 +41,6 @@ export interface Module {
|
|
|
41
41
|
set factoryMeta(factoryMeta: JsFactoryMeta);
|
|
42
42
|
get useSourceMap(): boolean;
|
|
43
43
|
get useSimpleSourceMap(): boolean;
|
|
44
|
-
get _readableIdentifier(): string;
|
|
45
44
|
buildInfo: BuildInfo;
|
|
46
45
|
buildMeta: Record<string, any>;
|
|
47
46
|
}
|
|
@@ -111,6 +110,7 @@ export declare class CodeGenerationResults {
|
|
|
111
110
|
export declare class ConcatenatedModule {
|
|
112
111
|
get rootModule(): Module
|
|
113
112
|
get modules(): Module[]
|
|
113
|
+
readableIdentifier(): string
|
|
114
114
|
_originalSource(): JsCompatSource | undefined
|
|
115
115
|
nameForCondition(): string | undefined
|
|
116
116
|
get blocks(): AsyncDependenciesBlock[]
|
|
@@ -121,6 +121,7 @@ export declare class ConcatenatedModule {
|
|
|
121
121
|
}
|
|
122
122
|
|
|
123
123
|
export declare class ContextModule {
|
|
124
|
+
readableIdentifier(): string
|
|
124
125
|
_originalSource(): JsCompatSource | undefined
|
|
125
126
|
nameForCondition(): string | undefined
|
|
126
127
|
get blocks(): AsyncDependenciesBlock[]
|
|
@@ -183,6 +184,7 @@ export declare class EntryOptionsDto {
|
|
|
183
184
|
export type EntryOptionsDTO = EntryOptionsDto
|
|
184
185
|
|
|
185
186
|
export declare class ExternalModule {
|
|
187
|
+
readableIdentifier(): string
|
|
186
188
|
_originalSource(): JsCompatSource | undefined
|
|
187
189
|
nameForCondition(): string | undefined
|
|
188
190
|
get blocks(): AsyncDependenciesBlock[]
|
|
@@ -404,6 +406,7 @@ export declare class KnownBuildInfo {
|
|
|
404
406
|
}
|
|
405
407
|
|
|
406
408
|
export declare class Module {
|
|
409
|
+
readableIdentifier(): string
|
|
407
410
|
_originalSource(): JsCompatSource | undefined
|
|
408
411
|
nameForCondition(): string | undefined
|
|
409
412
|
get blocks(): AsyncDependenciesBlock[]
|
|
@@ -520,6 +523,7 @@ export declare enum BuiltinPluginName {
|
|
|
520
523
|
SubresourceIntegrityPlugin = 'SubresourceIntegrityPlugin',
|
|
521
524
|
RsdoctorPlugin = 'RsdoctorPlugin',
|
|
522
525
|
RstestPlugin = 'RstestPlugin',
|
|
526
|
+
RslibPlugin = 'RslibPlugin',
|
|
523
527
|
CircularDependencyRspackPlugin = 'CircularDependencyRspackPlugin',
|
|
524
528
|
JsLoaderRspackPlugin = 'JsLoaderRspackPlugin',
|
|
525
529
|
LazyCompilationPlugin = 'LazyCompilationPlugin',
|
|
@@ -537,6 +541,8 @@ export interface ContextInfo {
|
|
|
537
541
|
|
|
538
542
|
export interface CssChunkingPluginOptions {
|
|
539
543
|
strict?: boolean
|
|
544
|
+
minSize?: number
|
|
545
|
+
maxSize?: number
|
|
540
546
|
exclude?: RegExp
|
|
541
547
|
}
|
|
542
548
|
|
|
@@ -2100,6 +2106,11 @@ export interface RawJavascriptParserOptions {
|
|
|
2100
2106
|
* @experimental
|
|
2101
2107
|
*/
|
|
2102
2108
|
inlineConst?: boolean
|
|
2109
|
+
/**
|
|
2110
|
+
* This option is experimental in Rspack only and subject to change or be removed anytime.
|
|
2111
|
+
* @experimental
|
|
2112
|
+
*/
|
|
2113
|
+
typeReexportsPresence?: string
|
|
2103
2114
|
}
|
|
2104
2115
|
|
|
2105
2116
|
export interface RawJsonGeneratorOptions {
|
|
@@ -2457,12 +2468,19 @@ export interface RawRsdoctorPluginOptions {
|
|
|
2457
2468
|
chunkGraphFeatures: boolean | Array<'graph' | 'assets'>
|
|
2458
2469
|
}
|
|
2459
2470
|
|
|
2471
|
+
export interface RawRslibPluginOptions {
|
|
2472
|
+
interceptApiPlugin: boolean
|
|
2473
|
+
}
|
|
2474
|
+
|
|
2460
2475
|
export interface RawRspackFuture {
|
|
2461
2476
|
|
|
2462
2477
|
}
|
|
2463
2478
|
|
|
2464
2479
|
export interface RawRstestPluginOptions {
|
|
2465
2480
|
injectModulePathName: boolean
|
|
2481
|
+
importMetaPathName: boolean
|
|
2482
|
+
hoistMockModule: boolean
|
|
2483
|
+
manualMockRoot: string
|
|
2466
2484
|
}
|
|
2467
2485
|
|
|
2468
2486
|
export interface RawRuleSetCondition {
|
package/binding.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const { existsSync
|
|
1
|
+
const { existsSync } = require('fs')
|
|
2
2
|
const { join } = require('path')
|
|
3
3
|
|
|
4
4
|
const { platform, arch } = process
|
|
@@ -8,18 +8,8 @@ let localFileExisted = false
|
|
|
8
8
|
let loadError = null
|
|
9
9
|
|
|
10
10
|
function isMusl() {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
try {
|
|
14
|
-
const lddPath = require('child_process').execSync('which ldd').toString().trim();
|
|
15
|
-
return readFileSync(lddPath, 'utf8').includes('musl')
|
|
16
|
-
} catch (e) {
|
|
17
|
-
return true
|
|
18
|
-
}
|
|
19
|
-
} else {
|
|
20
|
-
const { glibcVersionRuntime } = process.report.getReport().header
|
|
21
|
-
return !glibcVersionRuntime
|
|
22
|
-
}
|
|
11
|
+
const { glibcVersionRuntime } = process.report.getReport().header
|
|
12
|
+
return !glibcVersionRuntime
|
|
23
13
|
}
|
|
24
14
|
|
|
25
15
|
switch (platform) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rspack/binding",
|
|
3
|
-
"version": "1.4.0
|
|
3
|
+
"version": "1.4.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Node binding for rspack",
|
|
6
6
|
"main": "binding.js",
|
|
@@ -47,16 +47,16 @@
|
|
|
47
47
|
}
|
|
48
48
|
},
|
|
49
49
|
"optionalDependencies": {
|
|
50
|
-
"@rspack/binding-
|
|
51
|
-
"@rspack/binding-
|
|
52
|
-
"@rspack/binding-linux-arm64-
|
|
53
|
-
"@rspack/binding-linux-arm64-
|
|
54
|
-
"@rspack/binding-
|
|
55
|
-
"@rspack/binding-
|
|
56
|
-
"@rspack/binding-
|
|
57
|
-
"@rspack/binding-
|
|
58
|
-
"@rspack/binding-
|
|
59
|
-
"@rspack/binding-linux-x64-musl": "1.4.0
|
|
50
|
+
"@rspack/binding-win32-arm64-msvc": "1.4.0",
|
|
51
|
+
"@rspack/binding-darwin-arm64": "1.4.0",
|
|
52
|
+
"@rspack/binding-linux-arm64-gnu": "1.4.0",
|
|
53
|
+
"@rspack/binding-linux-arm64-musl": "1.4.0",
|
|
54
|
+
"@rspack/binding-wasm32-wasi": "1.4.0",
|
|
55
|
+
"@rspack/binding-darwin-x64": "1.4.0",
|
|
56
|
+
"@rspack/binding-win32-x64-msvc": "1.4.0",
|
|
57
|
+
"@rspack/binding-win32-ia32-msvc": "1.4.0",
|
|
58
|
+
"@rspack/binding-linux-x64-gnu": "1.4.0",
|
|
59
|
+
"@rspack/binding-linux-x64-musl": "1.4.0"
|
|
60
60
|
},
|
|
61
61
|
"scripts": {
|
|
62
62
|
"build:dev": "node scripts/build.js",
|