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

Commit b63076f

Browse files
authored
Merge pull request #215 from asigloo/hotifx/remove-vue-demi-rollup
fix(build): remove vue-demi
2 parents d9d7de5 + ed11af8 commit b63076f

File tree

17 files changed

+30
-49
lines changed

17 files changed

+30
-49
lines changed

dev/typescript/App.vue

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -81,10 +81,9 @@ import {
8181
email,
8282
pattern,
8383
ValidatorTrigger,
84-
ValidationTriggerTypes,
8584
TextAreaField,
86-
} from '../../src';
87-
/* } from '../../dist/as-dynamic-forms.esm'; */
85+
/* } from '../../src'; */
86+
} from '../../dist/as-dynamic-forms.esm';
8887
export default defineComponent({
8988
name: 'app',
9089
setup() {
@@ -236,7 +235,7 @@ export default defineComponent({
236235
validations: [emailValidator],
237236
238237
validationTrigger: ValidatorTrigger({
239-
type: ValidationTriggerTypes.CHANGE,
238+
type: 'change',
240239
threshold: 4,
241240
}),
242241
}),

package.json

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -45,10 +45,6 @@
4545
"jsdelivr": "dist/as-dynamic-forms.global.js",
4646
"module": "dist/as-dynamic-forms.esm-bundler.js",
4747
"types": "dist/as-dynamic-forms.d.ts",
48-
"peerDependencies": {
49-
"@vue/composition-api": "^1.0.0-beta.10",
50-
"vue": "^2.0.0 || >=3.0.4"
51-
},
5248
"devDependencies": {
5349
"@microsoft/api-extractor": "^7.12.0",
5450
"@rollup/plugin-alias": "^3.1.1",
@@ -95,7 +91,6 @@
9591
},
9692
"dependencies": {
9793
"deep-clone": "^3.0.3",
98-
"deep-object-diff": "^1.1.0",
99-
"vue-demi": "^0.5.3"
94+
"deep-object-diff": "^1.1.0"
10095
}
10196
}

rollup.config.js

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,6 @@ const outputConfigs = {
3333
file: pkg.main,
3434
format: `cjs`,
3535
},
36-
'global-vue-3': {
37-
file: pkg.unpkg.replace('2', '3'),
38-
format: `iife`,
39-
},
40-
'global-vue-2': {
41-
file: pkg.unpkg,
42-
format: `iife`,
43-
},
4436
esm: {
4537
file: pkg.browser,
4638
format: `es`,
@@ -56,7 +48,7 @@ function createConfig(format, output, plugins = []) {
5648
output.sourcemap = !!process.env.SOURCE_MAP;
5749
output.banner = banner;
5850
output.externalLiveBindings = false;
59-
output.globals = { 'vue-demi': 'VueDemi' };
51+
output.globals = { vue: 'Vue' };
6052

6153
const isProductionBuild = /\.prod\.js$/.test(output.file);
6254
const isGlobalBuild = format === 'global';
@@ -86,7 +78,7 @@ function createConfig(format, output, plugins = []) {
8678
// during a single build.
8779
/* hasTSChecked = true; */
8880

89-
const external = ['vue-demi'];
81+
const external = ['vue'];
9082

9183
const nodePlugins = [resolve(), commonjs()];
9284

src/components/checkbox-input/CheckboxInput.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script lang="ts">
2-
import { defineComponent, h, PropType } from 'vue-demi';
2+
import { defineComponent, h, PropType } from 'vue';
33
import { FormControl, CheckboxInput } from '@/core/models';
44
import { useInputEvents } from '@/composables/input-events';
55
import { useInputValidation } from '@/composables/use-validation';

src/components/dynamic-form/DynamicForm.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
</template>
3737

3838
<script lang="ts">
39-
import { nextTick } from 'vue-demi';
39+
import { nextTick } from 'vue';
4040
4141
import {
4242
defineComponent,
@@ -48,7 +48,7 @@ import {
4848
watch,
4949
inject,
5050
toRaw,
51-
} from 'vue-demi';
51+
} from 'vue';
5252
import { diff } from 'deep-object-diff';
5353
5454
import DynamicInput from '../dynamic-input/DynamicInput.vue';

src/components/dynamic-input/DynamicInput.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<script lang="ts">
22
/* eslint-disable @typescript-eslint/no-use-before-define */
33
4-
import { defineComponent, PropType, computed, h } from 'vue-demi';
4+
import { defineComponent, PropType, computed, h } from 'vue';
55
import TextInputComponent from '../text-input/TextInput.vue';
66
import SelectInputComponent from '../select-input/SelectInput.vue';
77
import TextAreaInputComponent from '../text-area-input/TextAreaInput.vue';

src/components/number-input/NumberInput.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script lang="ts">
2-
import { defineComponent, h, PropType } from 'vue-demi';
2+
import { defineComponent, h, PropType } from 'vue';
33
import { FormControl, NumberInput } from '@/core/models';
44
import { useInputEvents } from '@/composables/input-events';
55
import { useInputValidation } from '@/composables/use-validation';

src/components/radio-input/RadioInput.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script lang="ts">
2-
import { defineComponent, h, PropType } from 'vue-demi';
2+
import { defineComponent, h, PropType } from 'vue';
33
import { FormControl, RadioInput } from '@/core/models';
44
import { useInputEvents } from '@/composables/input-events';
55
import { useInputValidation } from '@/composables/use-validation';

src/components/select-input/SelectInput.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script lang="ts">
2-
import { defineComponent, h, PropType, computed } from 'vue-demi';
2+
import { defineComponent, h, PropType, computed } from 'vue';
33
import { FormControl, SelectInput } from '@/core/models';
44
import { useInputEvents } from '@/composables/input-events';
55
import { isObject } from '@/core/utils/helpers';

src/components/text-area-input/TextAreaInput.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<script lang="ts">
2-
import { defineComponent, h, PropType } from 'vue-demi';
2+
import { defineComponent, h, PropType } from 'vue';
33
import { FormControl, TextAreaInput } from '@/core/models';
44
import { useInputEvents } from '@/composables/input-events';
55
import { useInputValidation } from '@/composables/use-validation';

0 commit comments

Comments
 (0)