@anweb/nuxt-ancore 1.10.0 → 1.10.1

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/dist/module.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "AnCore",
3
3
  "configKey": "ancore",
4
- "version": "1.10.0",
4
+ "version": "1.10.1",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "1.0.2",
7
7
  "unbuild": "3.6.1"
@@ -10,7 +10,7 @@ export const useAnData = (initConfig) => {
10
10
  const Data = await useAsyncData(
11
11
  key,
12
12
  () => userApi(
13
- config.value.request,
13
+ key.value,
14
14
  { method: "GET", ...config.value.apiConfig || {} }
15
15
  )
16
16
  );
@@ -24,7 +24,7 @@ export const useAnData = (initConfig) => {
24
24
  const key = computed(() => {
25
25
  let url = config.value.request.toString();
26
26
  for (const key2 in config.value.params) {
27
- url.replace(`:${key2}`, encodeURIComponent(String(config.value.params[key2])));
27
+ url = url.replace(`:${key2}`, encodeURIComponent(String(config.value.params[key2])));
28
28
  }
29
29
  let query = "";
30
30
  if (config.value.apiConfig?.query) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@anweb/nuxt-ancore",
3
- "version": "1.10.0",
3
+ "version": "1.10.1",
4
4
  "description": "AnCore Nuxt module",
5
5
  "repository": "https://github.com/ANLTD/ancore",
6
6
  "license": "MIT",