Skip to content
This repository was archived by the owner on Jun 27, 2023. It is now read-only.

Commit ac879f0

Browse files
authored
Merge pull request #213 from asigloo/feature/vue-demi-test
Feature/vue demi test
2 parents a557fd0 + 59720c8 commit ac879f0

File tree

4 files changed

+58
-60
lines changed

4 files changed

+58
-60
lines changed

dev/typescript/main.ts

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ import { createApp } from 'vue';
33
import App from './App.vue';
44
import './styles/main.scss';
55

6-
import { createDynamicForms } from '../../src';
6+
/* import { createDynamicForms } from '../../src'; */
7+
8+
import { createDynamicForms } from '../../dist/as-dynamic-forms.esm';
79

8-
/* import { createDynamicForms } from '../../dist/as-dynamic-forms.esm';
9-
*/
1010
const VueDynamicForms = createDynamicForms({
1111
autoValidate: true,
1212
form: {

package-lock.json

+47-53
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@
8787
"semantic-release": "17.2.4",
8888
"ts-node": "^9.0.0",
8989
"typescript": "~4.1.2",
90-
"vue": "^3.0.0",
90+
"vue": "^3.0.4",
9191
"vue-select": "3.10.8",
9292
"postcss": "^7.0.35",
9393
"tailwindcss": "npm:@tailwindcss/postcss7-compat@^2.0.1"

rollup.config.js

+7-3
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,11 @@ const outputConfigs = {
3333
file: pkg.main,
3434
format: `cjs`,
3535
},
36-
global: {
36+
'global-vue-3': {
37+
file: pkg.unpkg.replace('2', '3'),
38+
format: `iife`,
39+
},
40+
'global-vue-2': {
3741
file: pkg.unpkg,
3842
format: `iife`,
3943
},
@@ -52,7 +56,7 @@ function createConfig(format, output, plugins = []) {
5256
output.sourcemap = !!process.env.SOURCE_MAP;
5357
output.banner = banner;
5458
output.externalLiveBindings = false;
55-
output.globals = { vue: 'Vue' };
59+
output.globals = { 'vue-demi': 'VueDemi' };
5660

5761
const isProductionBuild = /\.prod\.js$/.test(output.file);
5862
const isGlobalBuild = format === 'global';
@@ -82,7 +86,7 @@ function createConfig(format, output, plugins = []) {
8286
// during a single build.
8387
/* hasTSChecked = true; */
8488

85-
const external = ['vue'];
89+
const external = ['vue-demi'];
8690

8791
const nodePlugins = [resolve(), commonjs()];
8892

0 commit comments

Comments
 (0)