Skip to content

Commit

Permalink
fix: imports
Browse files Browse the repository at this point in the history
  • Loading branch information
farnabaz committed Dec 19, 2023
1 parent d2bcf70 commit f33f5a2
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 3 deletions.
2 changes: 2 additions & 0 deletions playground/basic/pages/[...slug].vue
Expand Up @@ -19,6 +19,8 @@
</template>

<script setup lang="ts">
import { definePageMeta } from '#imports'
definePageMeta({
layout: 'default',
layoutTransition: false
Expand Down
2 changes: 2 additions & 0 deletions playground/basic/pages/playground.vue
Expand Up @@ -5,6 +5,8 @@
</template>

<script setup lang="ts">
import { definePageMeta } from '#imports'
definePageMeta({
layout: 'default',
layoutTransition: false
Expand Down
1 change: 1 addition & 0 deletions playground/shared/components/NavItem.vue
@@ -1,4 +1,5 @@
<script setup lang="ts">
import { computed } from 'vue'
import type { NavItem } from '../../../src/runtime/types'
const props = defineProps<{
Expand Down
3 changes: 3 additions & 0 deletions playground/shared/components/PageNav.vue
@@ -1,4 +1,7 @@
<script setup lang="ts">
import { ref, watch } from 'vue'
import { useRoute } from '#vue-router'
const route = useRoute()
const navEl = ref()
Expand Down
2 changes: 2 additions & 0 deletions playground/shared/components/Playground.vue
Expand Up @@ -17,6 +17,8 @@
</template>

<script setup lang="ts">
import { ref } from 'vue'
const tab = ref('Preview')
const tabs = ref(['Preview', 'AST'])
const content = ref(`
Expand Down
2 changes: 1 addition & 1 deletion src/runtime/server/api/navigation.ts
@@ -1,9 +1,9 @@
import { cachedEventHandler } from 'nitropack/dist/runtime/cache'
import { cacheStorage, serverQueryContent } from '../storage'
import { createNav } from '../navigation'
import type { ParsedContent, ParsedContentMeta } from '../../types'
import { getContentQuery } from '../../utils/query'
import { isPreview } from '../preview'
import { cachedEventHandler } from '#imports'

export default cachedEventHandler(async (event) => {
const query = getContentQuery(event)
Expand Down
3 changes: 1 addition & 2 deletions src/runtime/server/api/query.ts
@@ -1,8 +1,7 @@
import { createError } from 'h3'
import { cachedEventHandler } from 'nitropack/dist/runtime/cache'
import { serverQueryContent } from '../storage'
import { getContentQuery } from '../../utils/query'
import { useRuntimeConfig } from '#imports'
import { useRuntimeConfig, cachedEventHandler } from '#imports'

export default cachedEventHandler(async (event) => {
const query = getContentQuery(event)
Expand Down

0 comments on commit f33f5a2

Please sign in to comment.