mooho-base-admin-plus 2.0.42 → 2.0.43

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mooho-base-admin-plus",
3
3
  "description": "MOOHO basic framework for admin by Vue3",
4
- "version": "2.0.42",
4
+ "version": "2.0.43",
5
5
  "author": "jinyifan <jinyifan@mooho.com.cn>",
6
6
  "license": "MIT",
7
7
  "private": false,
package/src/setting.js CHANGED
@@ -1,5 +1,3 @@
1
- import { assign } from 'lodash';
2
-
3
1
  /**
4
2
  * 默认配置
5
3
  * */
@@ -178,23 +176,23 @@ const Setting = {
178
176
  sameRouteForceUpdate: false
179
177
  };
180
178
 
181
- // const copyTo = (source, target) => {
182
- // for (let key in source) {
183
- // if (typeof source[key] === 'object') {
184
- // if (target[key] == null) {
185
- // target[key] = {};
186
- // }
187
- // copyTo(source[key], target[key]);
188
- // } else {
189
- // target[key] = source[key];
190
- // }
191
- // }
192
- // };
179
+ const copyTo = (source, target) => {
180
+ for (let key in source) {
181
+ if (typeof source[key] === 'object') {
182
+ if (target[key] == null) {
183
+ target[key] = {};
184
+ }
185
+ copyTo(source[key], target[key]);
186
+ } else {
187
+ target[key] = source[key];
188
+ }
189
+ }
190
+ };
193
191
 
194
192
  let localSetting = window.setting;
195
193
 
196
194
  if (localSetting) {
197
- assign(Setting, localSetting);
195
+ copyTo(localSetting, Setting);
198
196
  }
199
197
 
200
198
  export default Setting;
package/vite.config.js CHANGED
@@ -14,7 +14,8 @@ const build = defineConfig({
14
14
  },
15
15
  resolve: {
16
16
  alias: {
17
- '@': resolve(__dirname, '.', 'src')
17
+ '@': resolve(__dirname, '.', 'src'),
18
+ 'vue-i18n': 'vue-i18n/dist/vue-i18n.cjs.js'
18
19
  }
19
20
  // extensions: ['.js', '.json', '.vue']
20
21
  }
@@ -67,7 +68,8 @@ const lib = defineConfig({
67
68
  },
68
69
  resolve: {
69
70
  alias: {
70
- '@': resolve(__dirname, '.', 'src')
71
+ '@': resolve(__dirname, '.', 'src'),
72
+ 'vue-i18n': 'vue-i18n/dist/vue-i18n.cjs.js'
71
73
  }
72
74
  // extensions: ['.js', '.json', '.vue']
73
75
  }