mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-15 02:14:44 +00:00
26 lines
400 B
Vue
26 lines
400 B
Vue
|
<script setup>
|
||
|
const { enabled, state } = usePreviewMode()
|
||
|
|
||
|
const { data } = await useFetch('/api/preview', {
|
||
|
query: {
|
||
|
apiKey: state.token || undefined
|
||
|
}
|
||
|
})
|
||
|
</script>
|
||
|
|
||
|
<template>
|
||
|
<div>
|
||
|
<p id="enabled">
|
||
|
{{ enabled }}
|
||
|
</p>
|
||
|
|
||
|
<p id="token-check">
|
||
|
{{ state.token }}
|
||
|
</p>
|
||
|
|
||
|
<p id="correct-api-key-check">
|
||
|
{{ data && data.hehe }}
|
||
|
</p>
|
||
|
</div>
|
||
|
</template>
|