Skip to content

Commit 44b32b4

Browse files
committedDec 22, 2022
test: test compatibility with Vue CLI 4 & 5
1 parent b5f40eb commit 44b32b4

32 files changed

+19616
-297
lines changed
 

‎README.md

+29-5
Original file line numberDiff line numberDiff line change
@@ -679,6 +679,30 @@ export default {
679679

680680
<br>
681681

682+
### Vite
683+
684+
Ready to use right out of the box.
685+
686+
<br>
687+
688+
### Vue CLI 5 / webpack 5
689+
690+
Ready to use right out of the box.
691+
692+
<br>
693+
694+
### Vue CLI 4 / webpack 4
695+
696+
Vite 4 (Rollup 3) uses ES2020 as compiler target by default, therefore Vite-4-built outputs should be transpiled in webpack 4:
697+
698+
```js
699+
module.exports = {
700+
transpileDependencies: ['json-editor-vue'],
701+
}
702+
```
703+
704+
<br>
705+
682706
## Props
683707

684708
| Name | Description | Type | Default |
@@ -689,12 +713,12 @@ export default {
689713

690714
> ⚠ kebab-case is required for tag & prop name when using from CDN
691715
692-
### Binding value difference between `svelte-jsoneditor` and `json-editor-vue`
716+
### Binding value difference between 'svelte-jsoneditor' and 'json-editor-vue'
693717

694-
- `svelte-jsoneditor`: An object contains a stringified JSON or a parsed JSON, will do `JSON.parse` when passing as a stringified JSON.
695-
- `json-editor-vue`: JSON itself. What users see is what users get.
718+
- 'svelte-jsoneditor': An object contains a stringified JSON or a parsed JSON, will do `JSON.parse` when passing as a stringified JSON.
719+
- 'json-editor-vue': JSON itself. What users see is what users get.
696720

697-
If you prefer the behavior of `svelte-jsoneditor`:
721+
If you prefer the behavior of 'svelte-jsoneditor':
698722

699723
```html
700724
<JsonEditorVue
@@ -708,7 +732,7 @@ If you prefer the behavior of `svelte-jsoneditor`:
708732
709733
### Boolean properties
710734

711-
Including the boolean properties of `svelte-jsoneditor` like `readOnly` with no value will imply `true`:
735+
Including the boolean properties of 'svelte-jsoneditor' like `readOnly` with no value will imply `true`:
712736

713737
- ✔️ `<JsonEditorVue readOnly />`
714738

‎demo/vue-cli4/.browserslistrc

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
> 1%
2+
last 2 versions
3+
not dead

‎demo/vue-cli4/.gitignore

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
.DS_Store
2+
node_modules
3+
/dist
4+
5+
6+
# local env files
7+
.env.local
8+
.env.*.local
9+
10+
# Log files
11+
npm-debug.log*
12+
yarn-debug.log*
13+
yarn-error.log*
14+
pnpm-debug.log*
15+
16+
# Editor directories and files
17+
.idea
18+
.vscode
19+
*.suo
20+
*.ntvs*
21+
*.njsproj
22+
*.sln
23+
*.sw?

‎demo/vue-cli4/.node-version

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
14

‎demo/vue-cli4/README.md

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# vue-cli4
2+
3+
## Project setup
4+
```
5+
yarn install
6+
```
7+
8+
### Compiles and hot-reloads for development
9+
```
10+
yarn serve
11+
```
12+
13+
### Compiles and minifies for production
14+
```
15+
yarn build
16+
```
17+
18+
### Customize configuration
19+
See [Configuration Reference](https://cli.vuejs.org/config/).

‎demo/vue-cli4/babel.config.js

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
module.exports = {
2+
presets: [
3+
'@vue/cli-plugin-babel/preset'
4+
]
5+
}

0 commit comments

Comments
 (0)