hackmud-script-manager 0.19.0 → 0.19.1-01c1752
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +1 -3
- package/bin/hsm.d.ts +0 -0
- package/bin/hsm.js +436 -1
- package/constants.js +3 -1
- package/env.d.ts +1657 -0
- package/generateTypeDeclaration.d.ts +1 -2
- package/generateTypeDeclaration.js +68 -1
- package/index.d.ts +2 -2
- package/index.js +51 -1
- package/package.json +41 -38
- package/processScript/index.d.ts +17 -26
- package/processScript/index.js +333 -1
- package/processScript/minify.d.ts +15 -21
- package/processScript/minify.js +444 -1
- package/processScript/postprocess.d.ts +1 -2
- package/processScript/postprocess.js +20 -1
- package/processScript/preprocess.d.ts +7 -10
- package/processScript/preprocess.js +105 -1
- package/processScript/shared.d.ts +2 -2
- package/processScript/shared.js +32 -1
- package/processScript/transform.d.ts +13 -18
- package/processScript/transform.js +696 -1
- package/pull.d.ts +5 -9
- package/pull.js +11 -1
- package/push.d.ts +24 -33
- package/push.js +138 -1
- package/syncMacros.d.ts +1 -2
- package/syncMacros.js +43 -1
- package/watch.d.ts +10 -16
- package/watch.js +208 -1
- package/tsconfig.tsbuildinfo +0 -1
@@ -1,24 +1,19 @@
|
|
1
1
|
import type { File } from "@babel/types";
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
/** the user going to be hosting this script (or set to `true` if not yet known) */
|
6
|
-
scriptUser: string | true;
|
7
|
-
/** the name of this script (or set to `true` if not yet known) */
|
8
|
-
scriptName: string | true;
|
2
|
+
import type { LaxPartial } from "@samual/lib";
|
3
|
+
export type TransformOptions = LaxPartial<{
|
4
|
+
/** 11 a-z 0-9 characters */ uniqueId: string;
|
5
|
+
/** the user going to be hosting this script (or set to `true` if not yet known) */ scriptUser: string | true;
|
9
6
|
seclevel: number;
|
7
|
+
}> & {
|
8
|
+
scriptName: string | true;
|
10
9
|
};
|
11
|
-
/**
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
* @param options {@link TransformOptions details}
|
19
|
-
*/
|
20
|
-
export declare const transform: (file: File, sourceCode: string, { uniqueID, scriptUser, scriptName, seclevel }?: Partial<TransformOptions>) => {
|
10
|
+
/** transform a given babel `File` to be hackmud compatible
|
11
|
+
*
|
12
|
+
* (returned File will need `postprocess()`ing)
|
13
|
+
* @param file babel ast node representing a file containing preprocessed code
|
14
|
+
* @param sourceCode the original untouched source code
|
15
|
+
* @param options {@link TransformOptions details} */
|
16
|
+
export declare function transform(file: File, sourceCode: string, { uniqueId, scriptUser, scriptName, seclevel }: TransformOptions): {
|
21
17
|
file: File;
|
22
18
|
seclevel: number;
|
23
19
|
};
|
24
|
-
export default transform;
|