@devite/nuxt-sanity 2.5.3 → 2.6.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.
package/dist/module.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devite/nuxt-sanity",
3
- "version": "2.5.3",
3
+ "version": "2.6.0",
4
4
  "configKey": "sanity",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "0.8.4",
package/dist/module.mjs CHANGED
@@ -3,7 +3,7 @@ import { defineNuxtModule, createResolver, addPlugin, addServerHandler, addImpor
3
3
  import defu from 'defu';
4
4
 
5
5
  const name = "@devite/nuxt-sanity";
6
- const version = "2.5.3";
6
+ const version = "2.6.0";
7
7
 
8
8
  const CONFIG_KEY = "sanity";
9
9
  const module = defineNuxtModule({
@@ -128,14 +128,17 @@ const module = defineNuxtModule({
128
128
  useCdn: moduleConfig.useCdn,
129
129
  apiVersion: moduleConfig.apiVersion,
130
130
  perspective: "raw",
131
- /* Visual Editing */
132
131
  token: options.token || "",
133
132
  withCredentials: options.withCredentials || false,
133
+ /* Visual Editing */
134
134
  stega: moduleConfig.visualEditing && moduleConfig.visualEditing.stega !== false && moduleConfig.visualEditing.previewMode !== false && {
135
135
  enabled: true,
136
136
  studioUrl: moduleConfig.visualEditing.studioUrl
137
137
  } || {},
138
- visualEditing: moduleConfig.visualEditing
138
+ visualEditing: {
139
+ ...moduleConfig.visualEditing,
140
+ token: void 0
141
+ }
139
142
  });
140
143
  addImportsDir(resolve("runtime/client"));
141
144
  addImports(
@@ -5,6 +5,7 @@
5
5
  :key="module._key"
6
6
  :data="module"
7
7
  />
8
+ <slot />
8
9
  </main>
9
10
  </template>
10
11
 
@@ -31,7 +32,7 @@ if (sanityData.value?._type === 'notFound' && import.meta.server) {
31
32
  setResponseStatus(event, 404)
32
33
  }
33
34
 
34
- const { baseURL: baseUrl } = useRuntimeConfig().public
35
+ const { baseUrl } = useRuntimeConfig().public
35
36
  const seo = computed(() => sanityData.value?.seo)
36
37
  const url = computed(
37
38
  () =>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@devite/nuxt-sanity",
3
- "version": "2.5.3",
3
+ "version": "2.6.0",
4
4
  "description": "Advanced Sanity integration for Nuxt.js.",
5
5
  "repository": "devite-io/nuxt-sanity",
6
6
  "license": "MIT",