swico 2.8.0-beta.10 → 2.8.0-beta.12

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,6 +1,6 @@
1
1
  {
2
2
  "name": "swico",
3
- "version": "2.8.0-beta.10",
3
+ "version": "2.8.0-beta.12",
4
4
  "description": "Simple, efficient, and practical front-end framework",
5
5
  "main": "./src/index.js",
6
6
  "types": "./src/index.d.ts",
@@ -4,14 +4,14 @@ import { SwicoHistoryOptionType } from './typings/global-type';
4
4
  import { useLocation, useNav } from './template-root/.swico-react/hooks';
5
5
  export type CustomConfigType = GlobalData['customConfig'];
6
6
  export type { GlobalSwicoConfigType };
7
- interface PropsType {
7
+ interface LinkPropsType {
8
8
  replace?: boolean;
9
9
  to: string | number | SwicoHistoryOptionType;
10
10
  style?: CSSProperties;
11
11
  className?: string;
12
12
  children: ReactNode;
13
13
  }
14
- export declare const Link: FC<PropsType>;
14
+ export declare const Link: FC<LinkPropsType>;
15
15
  export { Outlet } from 'react-router';
16
16
  export { useLocation, useNav };
17
17
  export { history } from './mock-history';
@@ -2,35 +2,18 @@ import { GlobalData, GlobalSwicoConfigType } from './main-config';
2
2
  import { App } from 'vue';
3
3
  import { Router } from 'vue-router';
4
4
  import { useLocation, useNav } from './template-root/.swico-vue/hooks';
5
+ import { SwicoHistoryOptionType } from './typings/global-type';
5
6
  export type CustomConfigType = GlobalData['customConfig'];
6
7
  export { RouterView } from 'vue-router';
7
8
  export { useLocation, useNav };
8
9
  export { history } from './mock-history';
9
10
  export type { GlobalSwicoConfigType };
10
11
  export declare const Outlet: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
11
- export declare const Link: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
12
- to: {
13
- required: true;
14
- };
15
- replace: {
16
- type: BooleanConstructor;
17
- };
18
- }>, {
19
- nav: {
20
- (to: string, options?: import("./typings/global-type").NavOptionsType): void;
21
- (to: number): void;
22
- (to: import("./typings/global-type").SwicoHistoryOptionType, options?: import("./typings/global-type").NavOptionsType): void;
23
- };
24
- }, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
25
- to: {
26
- required: true;
27
- };
28
- replace: {
29
- type: BooleanConstructor;
30
- };
31
- }>> & Readonly<{}>, {
32
- replace: boolean;
33
- }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
12
+ interface LinkPropsType {
13
+ replace?: boolean;
14
+ to: string | number | SwicoHistoryOptionType;
15
+ }
16
+ export declare const Link: import("vue").DefineComponent<LinkPropsType, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<LinkPropsType> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
34
17
  export interface DefineSwicoConfigType {
35
18
  (env: 'base', config: CustomConfigType['base']): any;
36
19
  (env: 'dev', config: CustomConfigType['dev']): any;
@@ -125,8 +125,8 @@ export default function ({ projectPath, entryPath, env, customConfig }: GlobalDa
125
125
  '@': string;
126
126
  vue: string;
127
127
  'vue-router': string;
128
- swico: string;
129
128
  'swico/vue': string;
129
+ swico: string;
130
130
  qs: string;
131
131
  };
132
132
  };
@@ -254,7 +254,7 @@ function default_1(_a) {
254
254
  },
255
255
  resolve: {
256
256
  extensions: ['.ts', '.js', '.vue', '.json'],
257
- alias: Object.assign({ '@': path_1.default.join(projectPath, '/src'), vue: 'vue/dist/vue.esm-bundler.js', 'vue-router': path_1.default.dirname(require.resolve('vue-router')), swico: path_1.default.join(projectPath, '/.swico/index'), 'swico/vue': path_1.default.join(projectPath, '/.swico/index'), qs: path_1.default.dirname(require.resolve('qs')) }, getCustomAliasConfig())
257
+ alias: Object.assign({ '@': path_1.default.join(projectPath, '/src'), vue: 'vue/dist/vue.esm-bundler.js', 'vue-router': path_1.default.dirname(require.resolve('vue-router')), 'swico/vue': path_1.default.join(projectPath, '/.swico/index'), swico: path_1.default.join(projectPath, '/.swico/index'), qs: path_1.default.dirname(require.resolve('qs')) }, getCustomAliasConfig())
258
258
  },
259
259
  externals: customBaseConfig === null || customBaseConfig === void 0 ? void 0 : customBaseConfig.externals,
260
260
  plugins: [
@@ -24,7 +24,7 @@ const router = (0, history_1.getRouter)();
24
24
  const app = (0, vue_1.createApp)(Container);
25
25
  app.component('SwicoLayout', Layout_1.default);
26
26
  app.use(router);
27
+ (_a = global_1.default === null || global_1.default === void 0 ? void 0 : global_1.default.onInit) === null || _a === void 0 ? void 0 : _a.call(global_1.default, app, router);
27
28
  const rootEle = document.createElement('div');
28
29
  document.body.appendChild(rootEle);
29
30
  app.mount(rootEle);
30
- (_a = global_1.default === null || global_1.default === void 0 ? void 0 : global_1.default.onInit) === null || _a === void 0 ? void 0 : _a.call(global_1.default, app, router);