@parcel/rust 2.12.1-dev.3275 → 2.12.1-dev.3303
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/index.d.ts +28 -3
- package/index.js +3 -2
- package/index.js.flow +3 -5
- package/package.json +2 -2
- package/parcel-node-bindings.darwin-arm64.node +0 -0
- package/parcel-node-bindings.darwin-x64.node +0 -0
- package/parcel-node-bindings.linux-arm-gnueabihf.node +0 -0
- package/parcel-node-bindings.linux-arm64-gnu.node +0 -0
- package/parcel-node-bindings.linux-arm64-musl.node +0 -0
- package/parcel-node-bindings.linux-x64-gnu.node +0 -0
- package/parcel-node-bindings.linux-x64-musl.node +0 -0
- package/parcel-node-bindings.win32-x64-msvc.node +0 -0
package/index.d.ts
CHANGED
@@ -15,6 +15,31 @@ export function findNodeModule(module: string, from: string): string | null
|
|
15
15
|
export function hashString(s: string): string
|
16
16
|
export function hashBuffer(buf: Buffer): string
|
17
17
|
export function optimizeImage(kind: string, buf: Buffer): Buffer
|
18
|
+
/**
|
19
|
+
* JavaScript provided options to configure the `tracing_subscriber` rust logs into a file or the
|
20
|
+
* console.
|
21
|
+
*/
|
22
|
+
export interface ParcelTracingOptions {
|
23
|
+
/** Enable tracing */
|
24
|
+
enabled: boolean
|
25
|
+
/**
|
26
|
+
* If set to some, will trace to a file with the given options, otherwise the console will be
|
27
|
+
* used.
|
28
|
+
*/
|
29
|
+
outputFileOptions?: ParcelTracingOutputFileOptions
|
30
|
+
}
|
31
|
+
/**
|
32
|
+
* Output file configuration.
|
33
|
+
* Tracing log files will be rotated hourly on the provided directory.
|
34
|
+
*/
|
35
|
+
export interface ParcelTracingOutputFileOptions {
|
36
|
+
/** The directory where the log files will be written. */
|
37
|
+
directory: string
|
38
|
+
/** A prefix for the log file names. */
|
39
|
+
prefix: string
|
40
|
+
/** The maximum number of rotated files to keep. */
|
41
|
+
maxFiles: number
|
42
|
+
}
|
18
43
|
export interface ParcelNapiBuildOptions {
|
19
44
|
|
20
45
|
}
|
@@ -25,9 +50,9 @@ export interface ParcelNapiOptions {
|
|
25
50
|
threads?: number
|
26
51
|
nodeWorkers?: number
|
27
52
|
fs?: object
|
28
|
-
|
53
|
+
tracingOptions?: ParcelTracingOptions
|
29
54
|
}
|
30
|
-
export function
|
55
|
+
export function registerWorker(worker: object): void
|
31
56
|
export interface JsFileSystemOptions {
|
32
57
|
canonicalize: (...args: any[]) => any
|
33
58
|
read: (...args: any[]) => any
|
@@ -76,6 +101,7 @@ export interface JsInvalidations {
|
|
76
101
|
invalidateOnFileCreate: Array<FilePathCreateInvalidation | FileNameCreateInvalidation | GlobCreateInvalidation>
|
77
102
|
invalidateOnStartup: boolean
|
78
103
|
}
|
104
|
+
export function testingRunParcelJsTransformerPlugin(targetPath: string): unknown
|
79
105
|
export function transform(opts: object): unknown
|
80
106
|
export function transformAsync(opts: object): object
|
81
107
|
export class Hash {
|
@@ -91,7 +117,6 @@ export class ParcelNapi {
|
|
91
117
|
testingTempFsReadToString(path: string): Promise<string>
|
92
118
|
testingTempFsIsFile(path: string): Promise<boolean>
|
93
119
|
testingTempFsIsDir(path: string): Promise<boolean>
|
94
|
-
testingRpcPing(): Promise<void>
|
95
120
|
}
|
96
121
|
export class Resolver {
|
97
122
|
constructor(projectRoot: string, options: FileSystem)
|
package/index.js
CHANGED
@@ -310,7 +310,7 @@ if (!nativeBinding) {
|
|
310
310
|
throw new Error(`Failed to load native binding`)
|
311
311
|
}
|
312
312
|
|
313
|
-
const { initSentry, closeSentry, findAncestorFile, findFirstFile, findNodeModule, hashString, hashBuffer, Hash, optimizeImage, ParcelNapi,
|
313
|
+
const { initSentry, closeSentry, findAncestorFile, findFirstFile, findNodeModule, hashString, hashBuffer, Hash, optimizeImage, ParcelNapi, registerWorker, Resolver, testingRunParcelJsTransformerPlugin, transform, transformAsync } = nativeBinding
|
314
314
|
|
315
315
|
module.exports.initSentry = initSentry
|
316
316
|
module.exports.closeSentry = closeSentry
|
@@ -322,7 +322,8 @@ module.exports.hashBuffer = hashBuffer
|
|
322
322
|
module.exports.Hash = Hash
|
323
323
|
module.exports.optimizeImage = optimizeImage
|
324
324
|
module.exports.ParcelNapi = ParcelNapi
|
325
|
-
module.exports.
|
325
|
+
module.exports.registerWorker = registerWorker
|
326
326
|
module.exports.Resolver = Resolver
|
327
|
+
module.exports.testingRunParcelJsTransformerPlugin = testingRunParcelJsTransformerPlugin
|
327
328
|
module.exports.transform = transform
|
328
329
|
module.exports.transformAsync = transformAsync
|
package/index.js.flow
CHANGED
@@ -16,12 +16,10 @@ export interface ConfigRequest {
|
|
16
16
|
}
|
17
17
|
export interface RequestOptions {}
|
18
18
|
|
19
|
-
export type RpcCallback = (error: any, id: number, data: any, done: (value: {| Ok: any |} | {| Err: any |}) => any) => any | Promise<any>;
|
20
|
-
|
21
19
|
export interface ParcelNapiOptions {
|
22
|
-
|
20
|
+
threads?: number;
|
23
21
|
nodeWorkers?: number;
|
24
|
-
|
22
|
+
fs?: ParcelFileSystem;
|
25
23
|
}
|
26
24
|
|
27
25
|
declare export class ParcelNapi {
|
@@ -35,7 +33,7 @@ declare export class ParcelNapi {
|
|
35
33
|
testingRpcPing(): void;
|
36
34
|
}
|
37
35
|
|
38
|
-
declare export function
|
36
|
+
declare export function registerWorker(worker: any): void
|
39
37
|
|
40
38
|
declare export function initSentry(): void;
|
41
39
|
declare export function closeSentry(): void;
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@parcel/rust",
|
3
|
-
"version": "2.12.1-dev.
|
3
|
+
"version": "2.12.1-dev.3303+3edb0d741",
|
4
4
|
"license": "MIT",
|
5
5
|
"publishConfig": {
|
6
6
|
"access": "public"
|
@@ -40,5 +40,5 @@
|
|
40
40
|
"wasm:build": "cargo build -p parcel-node-bindings --target wasm32-unknown-unknown && cp ../../../target/wasm32-unknown-unknown/debug/parcel_node_bindings.wasm .",
|
41
41
|
"wasm:build-release": "CARGO_PROFILE_RELEASE_LTO=true cargo build -p parcel-node-bindings --target wasm32-unknown-unknown --release && wasm-opt --strip-debug -O ../../../target/wasm32-unknown-unknown/release/parcel_node_bindings.wasm -o parcel_node_bindings.wasm"
|
42
42
|
},
|
43
|
-
"gitHead": "
|
43
|
+
"gitHead": "3edb0d7419831e49cfa7ea8c52b4f7127a16ae52"
|
44
44
|
}
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|