swico 2.0.0-beta.37 → 2.0.0-beta.39

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/README.md CHANGED
@@ -7,7 +7,7 @@ Swico,发音近似于“斯威扣”。
7
7
 
8
8
  ## 主要特性
9
9
 
10
- - 构建工具基于Rspack 1.x,多线程驱动高度并行化计算,显著提升编译性能。
10
+ - 构建工具基于Rspack 1.x,基于Rust多线程驱动,显著提升编译性能。
11
11
 
12
12
  - 提供Vue3和React18两种开发模板选择,默认集成TypeScript5。同时最大化统一这两种模板的开发API。
13
13
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "swico",
3
- "version": "2.0.0-beta.37",
3
+ "version": "2.0.0-beta.39",
4
4
  "description": "Simple, efficient, and practical front-end framework",
5
5
  "main": "./src/index.js",
6
6
  "types": "./src/index.d.ts",
@@ -92,25 +92,7 @@ function default_1(options) {
92
92
  }
93
93
  }),
94
94
  new core_1.rspack.LightningCssMinimizerRspackPlugin({})
95
- ],
96
- splitChunks: {
97
- chunks: 'all',
98
- cacheGroups: {
99
- vendors: {
100
- test: /[\\/]node_modules[\\/]/,
101
- priority: -10,
102
- chunks: 'all',
103
- reuseExistingChunk: true
104
- },
105
- commons: {
106
- minSize: 0,
107
- minChunks: 2,
108
- priority: -20,
109
- chunks: 'all',
110
- reuseExistingChunk: true
111
- }
112
- }
113
- }
95
+ ]
114
96
  },
115
97
  plugins: [
116
98
  ...(isPublicDirExist || copyConfig.length > 0
package/src/index.d.ts CHANGED
@@ -1,5 +1,6 @@
1
1
  import { GlobalData, GlobalSwicoConfigType } from './utils/config';
2
2
  import { UseLocationType, UseNavType } from './typings/global-type';
3
+ export { rspack } from '@rspack/core';
3
4
  export type CustomConfigType = GlobalData['customConfig'];
4
5
  export type { GlobalSwicoConfigType };
5
6
  export { history } from './mock-history';
package/src/index.js CHANGED
@@ -1,6 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.defineGlobal = exports.defineConfig = exports.useNav = exports.useLocation = exports.Link = exports.Outlet = exports.history = void 0;
3
+ exports.defineGlobal = exports.defineConfig = exports.useNav = exports.useLocation = exports.Link = exports.Outlet = exports.history = exports.rspack = void 0;
4
+ var core_1 = require("@rspack/core");
5
+ Object.defineProperty(exports, "rspack", { enumerable: true, get: function () { return core_1.rspack; } });
4
6
  var mock_history_1 = require("./mock-history");
5
7
  Object.defineProperty(exports, "history", { enumerable: true, get: function () { return mock_history_1.history; } });
6
8
  let Outlet, Link, useLocation, useNav;
@@ -1,5 +1,6 @@
1
1
  import { GlobalData, GlobalSwicoConfigType } from './utils/config';
2
2
  import { CSSProperties, FC, ReactNode } from 'react';
3
+ export { rspack } from '@rspack/core';
3
4
  export type CustomConfigType = GlobalData['customConfig'];
4
5
  export type { GlobalSwicoConfigType };
5
6
  export declare const Link: FC<{
@@ -3,9 +3,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.defineGlobal = exports.defineConfig = exports.history = exports.useNav = exports.useLocation = exports.Outlet = exports.Link = void 0;
6
+ exports.defineGlobal = exports.defineConfig = exports.history = exports.useNav = exports.useLocation = exports.Outlet = exports.Link = exports.rspack = void 0;
7
7
  const react_router_1 = require("react-router");
8
8
  const react_1 = __importDefault(require("react"));
9
+ var core_1 = require("@rspack/core");
10
+ Object.defineProperty(exports, "rspack", { enumerable: true, get: function () { return core_1.rspack; } });
9
11
  const Link = ({ replace, to, style, className, children }) => react_1.default.createElement(react_router_1.Link, { replace, to, style, className }, children);
10
12
  exports.Link = Link;
11
13
  var react_router_2 = require("react-router");
@@ -5,6 +5,7 @@ export type CustomConfigType = GlobalData['customConfig'];
5
5
  export { RouterView as Outlet } from 'vue-router';
6
6
  export { useLocation, useNav } from './project-path/.swico-vue/vue-hooks';
7
7
  export { history } from './mock-history';
8
+ export { rspack } from '@rspack/core';
8
9
  export type { GlobalSwicoConfigType };
9
10
  export declare const Link: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
10
11
  to: {
package/src/index.vue.js CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.defineGlobal = exports.defineConfig = exports.Link = exports.history = exports.useNav = exports.useLocation = exports.Outlet = void 0;
3
+ exports.defineGlobal = exports.defineConfig = exports.Link = exports.rspack = exports.history = exports.useNav = exports.useLocation = exports.Outlet = void 0;
4
4
  const vue_1 = require("vue");
5
5
  const vue_router_1 = require("vue-router");
6
6
  var vue_router_2 = require("vue-router");
@@ -10,6 +10,8 @@ Object.defineProperty(exports, "useLocation", { enumerable: true, get: function
10
10
  Object.defineProperty(exports, "useNav", { enumerable: true, get: function () { return vue_hooks_1.useNav; } });
11
11
  var mock_history_1 = require("./mock-history");
12
12
  Object.defineProperty(exports, "history", { enumerable: true, get: function () { return mock_history_1.history; } });
13
+ var core_1 = require("@rspack/core");
14
+ Object.defineProperty(exports, "rspack", { enumerable: true, get: function () { return core_1.rspack; } });
13
15
  exports.Link = (0, vue_1.defineComponent)({
14
16
  components: {
15
17
  RouterLink: vue_router_1.RouterLink