@plasmicapp/loader-core 1.0.100 → 1.0.101
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/bundles.d.ts +9 -9
- package/dist/deps-graph.d.ts +12 -12
- package/dist/index.d.ts +6 -4
- package/dist/index.js +532 -5
- package/dist/index.js.map +7 -0
- package/dist/registry.d.ts +18 -18
- package/dist/tracker/index.d.ts +29 -29
- package/dist/tracker/utils.d.ts +13 -13
- package/package.json +16 -33
- package/dist/loader-core.cjs.development.js +0 -1268
- package/dist/loader-core.cjs.development.js.map +0 -1
- package/dist/loader-core.cjs.production.min.js +0 -2
- package/dist/loader-core.cjs.production.min.js.map +0 -1
- package/dist/loader-core.esm.js +0 -1248
- package/dist/loader-core.esm.js.map +0 -1
package/dist/registry.d.ts
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import { LoaderBundleOutput } from '@plasmicapp/loader-fetcher';
|
|
2
|
-
export declare class Registry {
|
|
3
|
-
private loadedModules;
|
|
4
|
-
private registeredModules;
|
|
5
|
-
private modules;
|
|
6
|
-
constructor();
|
|
7
|
-
register(name: string, module: any): void;
|
|
8
|
-
isEmpty(): boolean;
|
|
9
|
-
clear(): void;
|
|
10
|
-
getRegisteredModule(name: string): any;
|
|
11
|
-
hasModule(name: string, opts?: {
|
|
12
|
-
forceOriginal?: boolean;
|
|
13
|
-
}): boolean;
|
|
14
|
-
load(name: string, opts?: {
|
|
15
|
-
forceOriginal?: boolean;
|
|
16
|
-
}): any;
|
|
17
|
-
updateModules(bundle: LoaderBundleOutput): void;
|
|
18
|
-
}
|
|
1
|
+
import { LoaderBundleOutput } from '@plasmicapp/loader-fetcher';
|
|
2
|
+
export declare class Registry {
|
|
3
|
+
private loadedModules;
|
|
4
|
+
private registeredModules;
|
|
5
|
+
private modules;
|
|
6
|
+
constructor();
|
|
7
|
+
register(name: string, module: any): void;
|
|
8
|
+
isEmpty(): boolean;
|
|
9
|
+
clear(): void;
|
|
10
|
+
getRegisteredModule(name: string): any;
|
|
11
|
+
hasModule(name: string, opts?: {
|
|
12
|
+
forceOriginal?: boolean;
|
|
13
|
+
}): boolean;
|
|
14
|
+
load(name: string, opts?: {
|
|
15
|
+
forceOriginal?: boolean;
|
|
16
|
+
}): any;
|
|
17
|
+
updateModules(bundle: LoaderBundleOutput): void;
|
|
18
|
+
}
|
package/dist/tracker/index.d.ts
CHANGED
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
export interface TrackerOptions {
|
|
2
|
-
projectIds: string[];
|
|
3
|
-
host?: string;
|
|
4
|
-
platform?: string;
|
|
5
|
-
preview?: boolean;
|
|
6
|
-
}
|
|
7
|
-
export interface TrackerRenderProperties {
|
|
8
|
-
rootProjectId?: string;
|
|
9
|
-
rootComponentId?: string;
|
|
10
|
-
rootComponentName?: string;
|
|
11
|
-
teamIds: string[];
|
|
12
|
-
projectIds: string[];
|
|
13
|
-
}
|
|
14
|
-
export interface TrackRenderOptions {
|
|
15
|
-
renderCtx?: TrackerRenderProperties;
|
|
16
|
-
variation?: Record<string, string>;
|
|
17
|
-
}
|
|
18
|
-
export declare class PlasmicTracker {
|
|
19
|
-
private opts;
|
|
20
|
-
private eventQueue;
|
|
21
|
-
constructor(opts: TrackerOptions);
|
|
22
|
-
trackRender(opts?: TrackRenderOptions): void;
|
|
23
|
-
trackFetch(): void;
|
|
24
|
-
trackConversion(value?: number): void;
|
|
25
|
-
private getProperties;
|
|
26
|
-
private enqueue;
|
|
27
|
-
private getContextMeta;
|
|
28
|
-
private sendEvents;
|
|
29
|
-
}
|
|
1
|
+
export interface TrackerOptions {
|
|
2
|
+
projectIds: string[];
|
|
3
|
+
host?: string;
|
|
4
|
+
platform?: string;
|
|
5
|
+
preview?: boolean;
|
|
6
|
+
}
|
|
7
|
+
export interface TrackerRenderProperties {
|
|
8
|
+
rootProjectId?: string;
|
|
9
|
+
rootComponentId?: string;
|
|
10
|
+
rootComponentName?: string;
|
|
11
|
+
teamIds: string[];
|
|
12
|
+
projectIds: string[];
|
|
13
|
+
}
|
|
14
|
+
export interface TrackRenderOptions {
|
|
15
|
+
renderCtx?: TrackerRenderProperties;
|
|
16
|
+
variation?: Record<string, string>;
|
|
17
|
+
}
|
|
18
|
+
export declare class PlasmicTracker {
|
|
19
|
+
private opts;
|
|
20
|
+
private eventQueue;
|
|
21
|
+
constructor(opts: TrackerOptions);
|
|
22
|
+
trackRender(opts?: TrackRenderOptions): void;
|
|
23
|
+
trackFetch(): void;
|
|
24
|
+
trackConversion(value?: number): void;
|
|
25
|
+
private getProperties;
|
|
26
|
+
private enqueue;
|
|
27
|
+
private getContextMeta;
|
|
28
|
+
private sendEvents;
|
|
29
|
+
}
|
package/dist/tracker/utils.d.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
export declare function getPlasmicCookieValues(): {
|
|
2
|
-
[k: string]: string;
|
|
3
|
-
};
|
|
4
|
-
export declare function getVariationCookieValues(): any;
|
|
5
|
-
export declare function generateUUID(): string;
|
|
6
|
-
export declare function getDistinctId(): string;
|
|
7
|
-
export declare function getWindowMeta(): {};
|
|
8
|
-
export declare function getEnvMeta(): {
|
|
9
|
-
isBrowser: boolean;
|
|
10
|
-
isProduction: boolean;
|
|
11
|
-
};
|
|
12
|
-
export declare function rawSplitVariation(variation: Record<string, string>): Record<string, string>;
|
|
13
|
-
export declare function throttled<T>(func: (param: T) => Promise<void>): (param: T) => void;
|
|
1
|
+
export declare function getPlasmicCookieValues(): {
|
|
2
|
+
[k: string]: string;
|
|
3
|
+
};
|
|
4
|
+
export declare function getVariationCookieValues(): any;
|
|
5
|
+
export declare function generateUUID(): string;
|
|
6
|
+
export declare function getDistinctId(): string;
|
|
7
|
+
export declare function getWindowMeta(): {};
|
|
8
|
+
export declare function getEnvMeta(): {
|
|
9
|
+
isBrowser: boolean;
|
|
10
|
+
isProduction: boolean;
|
|
11
|
+
};
|
|
12
|
+
export declare function rawSplitVariation(variation: Record<string, string>): Record<string, string>;
|
|
13
|
+
export declare function throttled<T>(func: (param: T) => Promise<void>): (param: T) => void;
|
package/package.json
CHANGED
|
@@ -1,8 +1,14 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "1.0.
|
|
2
|
+
"version": "1.0.101",
|
|
3
3
|
"license": "MIT",
|
|
4
|
-
"
|
|
5
|
-
"
|
|
4
|
+
"types": "./dist/index.d.ts",
|
|
5
|
+
"main": "./dist/index.js",
|
|
6
|
+
"exports": {
|
|
7
|
+
".": {
|
|
8
|
+
"types": "./dist/index.d.ts",
|
|
9
|
+
"default": "./dist/index.js"
|
|
10
|
+
}
|
|
11
|
+
},
|
|
6
12
|
"files": [
|
|
7
13
|
"dist"
|
|
8
14
|
],
|
|
@@ -10,50 +16,27 @@
|
|
|
10
16
|
"node": ">=10"
|
|
11
17
|
},
|
|
12
18
|
"scripts": {
|
|
13
|
-
"
|
|
14
|
-
"build": "
|
|
15
|
-
"
|
|
19
|
+
"build": "yarn build:types && yarn build:index",
|
|
20
|
+
"build:types": "yarn tsc",
|
|
21
|
+
"build:index": "node ../../build.mjs ./src/index.ts",
|
|
16
22
|
"yalcp": "yalc publish --push",
|
|
17
23
|
"test": "yarn --cwd=../.. test",
|
|
18
|
-
"lint": "
|
|
24
|
+
"lint": "eslint",
|
|
19
25
|
"prepare": "if-env PREPARE_NO_BUILD=true || yarn build",
|
|
20
26
|
"size": "size-limit",
|
|
21
27
|
"analyze": "size-limit --why"
|
|
22
28
|
},
|
|
23
|
-
"husky": {
|
|
24
|
-
"hooks": {
|
|
25
|
-
"pre-commit": "tsdx lint"
|
|
26
|
-
}
|
|
27
|
-
},
|
|
28
|
-
"prettier": {
|
|
29
|
-
"printWidth": 80,
|
|
30
|
-
"semi": true,
|
|
31
|
-
"singleQuote": true,
|
|
32
|
-
"trailingComma": "es5"
|
|
33
|
-
},
|
|
34
29
|
"name": "@plasmicapp/loader-core",
|
|
35
30
|
"author": "Chung Wu",
|
|
36
|
-
"module": "dist/loader-core.esm.js",
|
|
37
31
|
"size-limit": [
|
|
38
32
|
{
|
|
39
|
-
"path": "dist/
|
|
40
|
-
"limit": "10 KB"
|
|
41
|
-
},
|
|
42
|
-
{
|
|
43
|
-
"path": "dist/loader-core.esm.js",
|
|
33
|
+
"path": "dist/index.js",
|
|
44
34
|
"limit": "10 KB"
|
|
45
35
|
}
|
|
46
36
|
],
|
|
47
|
-
"devDependencies": {
|
|
48
|
-
"@size-limit/preset-small-lib": "^4.11.0",
|
|
49
|
-
"husky": "^6.0.0",
|
|
50
|
-
"size-limit": "^4.11.0",
|
|
51
|
-
"tsdx": "^0.14.1",
|
|
52
|
-
"tslib": "^2.2.0"
|
|
53
|
-
},
|
|
54
37
|
"dependencies": {
|
|
55
38
|
"@plasmicapp/isomorphic-unfetch": "^1.0.1",
|
|
56
|
-
"@plasmicapp/loader-fetcher": "1.0.
|
|
39
|
+
"@plasmicapp/loader-fetcher": "1.0.24"
|
|
57
40
|
},
|
|
58
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "1d6d699a0dfb9781ecac5e8df1dfc3a690c43559"
|
|
59
42
|
}
|