@tuya-sat/micro-script 3.0.0-beta.23 → 3.0.0-beta.25

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.
@@ -12,5 +12,6 @@ declare const _default: {
12
12
  vueJsEntryFile: string;
13
13
  ReactTsEntryFile: string;
14
14
  ReactJsEntryFile: string;
15
+ node_modules: string;
15
16
  };
16
17
  export default _default;
@@ -19,4 +19,5 @@ exports.default = {
19
19
  vueJsEntryFile: path_1.default.resolve(cwd, "src/index.js"),
20
20
  ReactTsEntryFile: path_1.default.resolve(cwd, "src/index.tsx"),
21
21
  ReactJsEntryFile: path_1.default.resolve(cwd, "src/index.jsx"),
22
+ node_modules: path_1.default.resolve(cwd, "node_modules")
22
23
  };
@@ -67,7 +67,7 @@ function getCommonConfig({ isDev, isBuild, }) {
67
67
  ].filter(Boolean);
68
68
  return loaders;
69
69
  };
70
- const { multiApps } = require(paths_1.default.microConfig);
70
+ const { multiApps, debuggerConfig: { isMainApp } } = require(paths_1.default.microConfig);
71
71
  const multiAppsWebpackConfig = {
72
72
  plugins: [],
73
73
  entry: {},
@@ -185,7 +185,13 @@ function getCommonConfig({ isDev, isBuild, }) {
185
185
  filter: (resourcePath) => __awaiter(this, void 0, void 0, function* () { return resourcePath !== paths_1.default.spaHtml; }),
186
186
  noErrorOnMissing: true,
187
187
  },
188
- ],
188
+ isMainApp && {
189
+ from: `${paths_1.default.node_modules}/@tuya-sat/sdf-main-sdk/dist/**/*.png`,
190
+ to() {
191
+ return "static/img/[name][ext]";
192
+ },
193
+ },
194
+ ].filter((value) => Boolean(value)),
189
195
  }),
190
196
  isBuild &&
191
197
  new mini_css_extract_plugin_1.default({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tuya-sat/micro-script",
3
- "version": "3.0.0-beta.23",
3
+ "version": "3.0.0-beta.25",
4
4
  "bin": "./dist/bin/cli.js",
5
5
  "type": "commonjs",
6
6
  "license": "MIT",
@@ -20,9 +20,9 @@
20
20
  "@babel/preset-react": "7.16.7",
21
21
  "@babel/preset-typescript": "7.16.7",
22
22
  "@pmmmwh/react-refresh-webpack-plugin": "0.5.4",
23
- "@tuya-sat/micro-dev-loader": "3.0.0-beta.23",
24
- "@tuya-sat/micro-dev-proxy": "3.0.0-beta.23",
25
- "@tuya-sat/micro-utils": "3.0.0-beta.23",
23
+ "@tuya-sat/micro-dev-loader": "3.0.0-beta.25",
24
+ "@tuya-sat/micro-dev-proxy": "3.0.0-beta.25",
25
+ "@tuya-sat/micro-utils": "3.0.0-beta.25",
26
26
  "@types/kill-port": "^2.0.0",
27
27
  "babel-loader": "8.2.4",
28
28
  "babel-plugin-import": "1.13.3",