create-packer 1.26.0 → 1.26.2

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": "create-packer",
3
- "version": "1.26.0",
3
+ "version": "1.26.2",
4
4
  "main": "index.js",
5
5
  "repository": "https://github.com/kevily/create-packer",
6
6
  "author": "1k <bug_zero@163.com>",
@@ -1,6 +1,6 @@
1
- import defineModel from 'define-zustand'
1
+ import { defineStore } from 'define-zustand'
2
2
 
3
- export const useApp = defineModel({
3
+ export const useApp = defineStore({
4
4
  state: () => ({}),
5
5
  getter: {},
6
6
  actions: () => ({})
@@ -20,7 +20,7 @@
20
20
  "dependencies": {
21
21
  "1k-types": "1.1.2",
22
22
  "axios": "1.3.6",
23
- "define-zustand": "2.0.1",
23
+ "define-zustand": "3.1.0",
24
24
  "immer": "10.0.1",
25
25
  "lodash-es": "4.17.21",
26
26
  "qs": "6.11.2",
@@ -1,6 +1,6 @@
1
- import defineModel from 'define-zustand'
1
+ import { defineStore } from 'define-zustand'
2
2
 
3
- export const useApp = defineModel({
3
+ export const useApp = defineStore({
4
4
  state: () => ({}),
5
5
  getter: {},
6
6
  actions: () => ({})
@@ -21,7 +21,7 @@
21
21
  "dependencies": {
22
22
  "1k-types": "1.1.2",
23
23
  "axios": "1.5.0",
24
- "define-zustand": "2.0.1",
24
+ "define-zustand": "3.1.0",
25
25
  "immer": "10.0.2",
26
26
  "lodash-es": "4.17.21",
27
27
  "qs": "6.11.2",
@@ -17,7 +17,7 @@
17
17
  "commit": "git add . && npm run cz"
18
18
  },
19
19
  "dependencies": {
20
- "define-zustand": "2.0.1",
20
+ "define-zustand": "3.1.0",
21
21
  "immer": "10.0.1",
22
22
  "ky": "1.1.3",
23
23
  "lodash-es": "4.17.21",
@@ -21,8 +21,14 @@ function createServiceHooks() {
21
21
  async req => {
22
22
  // eslint-disable-next-line prefer-const
23
23
  let [url, searchParams] = req.url.split('?')
24
- const reqBody =
25
- !includes(['GET', 'HEAD'], req.method) && req.body ? await req.json() : void 0
24
+ let reqBody = void 0
25
+ if (!includes(['GET', 'HEAD'], req.method)) {
26
+ try {
27
+ reqBody = await req.json()
28
+ } catch {
29
+ /* empty */
30
+ }
31
+ }
26
32
  const parsedSearchParams = parse(searchParams)
27
33
  const reqConfig = {
28
34
  searchParams: parsedSearchParams,
@@ -0,0 +1,22 @@
1
+ # ignore most things, include some others
2
+ /*
3
+ /.*
4
+
5
+ !bin/
6
+ !lib/
7
+ !docs/
8
+ !package.json
9
+ !package-lock.json
10
+ !README.md
11
+ !CONTRIBUTING.md
12
+ !LICENSE
13
+ !CHANGELOG.md
14
+ !example/
15
+ !scripts/
16
+ !tap-snapshots/
17
+ !test/
18
+ !.travis.yml
19
+ !.gitignore
20
+ !.gitattributes
21
+ !coverage-map.js
22
+ !index.js
@@ -0,0 +1,22 @@
1
+ # ignore most things, include some others
2
+ /*
3
+ /.*
4
+
5
+ !bin/
6
+ !lib/
7
+ !docs/
8
+ !package.json
9
+ !package-lock.json
10
+ !README.md
11
+ !CONTRIBUTING.md
12
+ !LICENSE
13
+ !CHANGELOG.md
14
+ !example/
15
+ !scripts/
16
+ !tap-snapshots/
17
+ !test/
18
+ !.travis.yml
19
+ !.gitignore
20
+ !.gitattributes
21
+ !coverage-map.js
22
+ !index.js
@@ -0,0 +1,22 @@
1
+ # ignore most things, include some others
2
+ /*
3
+ /.*
4
+
5
+ !bin/
6
+ !lib/
7
+ !docs/
8
+ !package.json
9
+ !package-lock.json
10
+ !README.md
11
+ !CONTRIBUTING.md
12
+ !LICENSE
13
+ !CHANGELOG.md
14
+ !example/
15
+ !scripts/
16
+ !tap-snapshots/
17
+ !test/
18
+ !.travis.yml
19
+ !.gitignore
20
+ !.gitattributes
21
+ !coverage-map.js
22
+ !index.js
@@ -0,0 +1,24 @@
1
+ # ignore most things, include some others
2
+ /*
3
+ /.*
4
+
5
+ !bin/
6
+ !lib/
7
+ !docs/
8
+ !package.json
9
+ !package-lock.json
10
+ !README.md
11
+ !CONTRIBUTING.md
12
+ !LICENSE
13
+ !CHANGELOG.md
14
+ !example/
15
+ !scripts/
16
+ !tap-snapshots/
17
+ !test/
18
+ !.github/
19
+ !.travis.yml
20
+ !.gitignore
21
+ !.gitattributes
22
+ !coverage-map.js
23
+ !map.js
24
+ !index.js
@@ -0,0 +1,24 @@
1
+ # ignore most things, include some others
2
+ /*
3
+ /.*
4
+
5
+ !bin/
6
+ !lib/
7
+ !docs/
8
+ !package.json
9
+ !package-lock.json
10
+ !README.md
11
+ !CONTRIBUTING.md
12
+ !LICENSE
13
+ !CHANGELOG.md
14
+ !example/
15
+ !scripts/
16
+ !tap-snapshots/
17
+ !test/
18
+ !.github/
19
+ !.travis.yml
20
+ !.gitignore
21
+ !.gitattributes
22
+ !coverage-map.js
23
+ !map.js
24
+ !index.js
@@ -0,0 +1,24 @@
1
+ # ignore most things, include some others
2
+ /*
3
+ /.*
4
+
5
+ !bin/
6
+ !lib/
7
+ !docs/
8
+ !package.json
9
+ !package-lock.json
10
+ !README.md
11
+ !CONTRIBUTING.md
12
+ !LICENSE
13
+ !CHANGELOG.md
14
+ !example/
15
+ !scripts/
16
+ !tap-snapshots/
17
+ !test/
18
+ !.github/
19
+ !.travis.yml
20
+ !.gitignore
21
+ !.gitattributes
22
+ !coverage-map.js
23
+ !map.js
24
+ !index.js
@@ -0,0 +1,24 @@
1
+ # ignore most things, include some others
2
+ /*
3
+ /.*
4
+
5
+ !bin/
6
+ !lib/
7
+ !docs/
8
+ !package.json
9
+ !package-lock.json
10
+ !README.md
11
+ !CONTRIBUTING.md
12
+ !LICENSE
13
+ !CHANGELOG.md
14
+ !example/
15
+ !scripts/
16
+ !tap-snapshots/
17
+ !test/
18
+ !.github/
19
+ !.travis.yml
20
+ !.gitignore
21
+ !.gitattributes
22
+ !coverage-map.js
23
+ !map.js
24
+ !index.js