@embeddable.com/sdk-react 4.0.3 → 4.0.4
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/lib/dynamicImportHandler.js +14 -0
- package/lib/index.esm.js.map +1 -1
- package/lib/index.js +26 -29
- package/lib/index.js.map +1 -1
- package/lib/plugin.d.ts +21 -0
- package/lib/proxyHandler.d.ts +4 -0
- package/lib/utils/modules.d.ts +13 -0
- package/lib/validate/errorFormatter.d.ts +3 -0
- package/package.json +2 -2
package/lib/plugin.d.ts
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { ModuleInfo } from "rollup";
|
|
2
|
+
declare const _default: ({
|
|
3
|
+
globalKey,
|
|
4
|
+
outputDir,
|
|
5
|
+
fileName,
|
|
6
|
+
componentFileRegex,
|
|
7
|
+
typeFileRegex,
|
|
8
|
+
searchEntry,
|
|
9
|
+
}: {
|
|
10
|
+
globalKey: string;
|
|
11
|
+
outputDir: string;
|
|
12
|
+
fileName: string;
|
|
13
|
+
componentFileRegex: RegExp;
|
|
14
|
+
typeFileRegex: RegExp;
|
|
15
|
+
searchEntry?: string | undefined;
|
|
16
|
+
}) => {
|
|
17
|
+
name: string;
|
|
18
|
+
moduleParsed: (moduleInfo: ModuleInfo) => Promise<void>;
|
|
19
|
+
buildEnd: () => Promise<void>;
|
|
20
|
+
};
|
|
21
|
+
export default _default;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Check if a file is a React component file
|
|
3
|
+
* @param moduleId - The module ID of the file
|
|
4
|
+
* @param relativeModulePath - The relative path of the file
|
|
5
|
+
* @returns Whether the file is a React component file
|
|
6
|
+
* @example
|
|
7
|
+
* isReactComponentFile("path/to/file.ts", "./component.tsx");
|
|
8
|
+
* // => true
|
|
9
|
+
* */
|
|
10
|
+
export declare const isReactComponentFile: (
|
|
11
|
+
moduleId: string,
|
|
12
|
+
relativeModulePath: string,
|
|
13
|
+
) => boolean;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@embeddable.com/sdk-react",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.4",
|
|
4
4
|
"description": "Embeddable SDK React plugin responsible for React components bundling.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"embeddable",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"@babel/generator": "^7.23.0",
|
|
35
35
|
"@babel/parser": "^7.26.2",
|
|
36
36
|
"@babel/traverse": "^7.24.7",
|
|
37
|
-
"@embeddable.com/sdk-core": "4.0
|
|
37
|
+
"@embeddable.com/sdk-core": "4.1.0",
|
|
38
38
|
"@embeddable.com/sdk-utils": "0.8.2",
|
|
39
39
|
"@happy-dom/global-registrator": "^15.11.0",
|
|
40
40
|
"@vitejs/plugin-react": "^4.3.2",
|