@vesperjs/nuxt 0.6.0 → 0.7.0
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.
|
@@ -71,7 +71,7 @@ export const useMutationApi = async function <T = unknown, E = any>(
|
|
|
71
71
|
if (onRequestError) mutOptions.onRequestError = onRequestError
|
|
72
72
|
if (onResponseError) mutOptions.onResponseError = onResponseError
|
|
73
73
|
|
|
74
|
-
if (method
|
|
74
|
+
if (method === 'post' || method === 'put') mutOptions.body = body
|
|
75
75
|
|
|
76
76
|
mutOptions.onResponse = ({ response }: { response: FetchResponse<T> }) => {
|
|
77
77
|
tokenRef.value = response.headers.get('Authorization')?.split(' ')[1] ?? token
|
|
@@ -2,7 +2,7 @@ import { useState } from 'nuxt/app'
|
|
|
2
2
|
|
|
3
3
|
export const useMoreScroll = function ({
|
|
4
4
|
key = null,
|
|
5
|
-
page,
|
|
5
|
+
page = 1,
|
|
6
6
|
pages,
|
|
7
7
|
}: {
|
|
8
8
|
key?: string | null
|
|
@@ -49,8 +49,8 @@ export const useMoreScroll = function ({
|
|
|
49
49
|
}
|
|
50
50
|
|
|
51
51
|
const pagePrevNext = () => {
|
|
52
|
-
if (currentPage.value
|
|
53
|
-
if (currentPage.value
|
|
52
|
+
if (currentPage.value === 1) pagePrev.value = false
|
|
53
|
+
if (currentPage.value === pages) pageNext.value = false
|
|
54
54
|
// console.log(`page prev: ${pagePrev.value}`)
|
|
55
55
|
// console.log(`page next: ${pageNext.value}`)
|
|
56
56
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vesperjs/nuxt",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.0",
|
|
4
4
|
"keywords": [
|
|
5
5
|
"nuxt",
|
|
6
6
|
"vue.js"
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"@nuxt/eslint": "1.15.2",
|
|
25
25
|
"@nuxtjs/i18n": "^10.3.0",
|
|
26
26
|
"@types/node": "^24.12.2",
|
|
27
|
-
"@vesperjs/shared": "0.
|
|
27
|
+
"@vesperjs/shared": "0.7.0",
|
|
28
28
|
"eslint": "^10.3.0",
|
|
29
29
|
"eslint-typegen": "2.3.1",
|
|
30
30
|
"nuxt": "^4.3.1",
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"typescript": "^6.0.3"
|
|
34
34
|
},
|
|
35
35
|
"peerDependencies": {
|
|
36
|
-
"vue": "^3.5.34 || ^3.6.0-beta.
|
|
36
|
+
"vue": "^3.5.34 || ^3.6.0-beta.11"
|
|
37
37
|
},
|
|
38
38
|
"scripts": {
|
|
39
39
|
"dev": "nuxi dev .playground",
|