# SliceZone Nuxt 3 error with type imports in slices

**URL:** <https://community.prismic.io/t/slicezone-nuxt-3-error-with-type-imports-in-slices/14753>\
**Category:** Developing with Prismic\
**Tags:** nuxtjs, slice-machine\
**Created:** [December 13, 2023, 2:12pm UTC](https://community.prismic.io/t/slicezone-nuxt-3-error-with-type-imports-in-slices/14753 "2023-12-13T14:12:39Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![danyaviless18](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/danyaviless18/32/8137_2.png) [@danyaviless18](https://community.prismic.io/u/danyaviless18)\
**Post date:** [December 13, 2023, 2:12pm UTC](https://community.prismic.io/t/slicezone-nuxt-3-error-with-type-imports-in-slices/14753/1 "2023-12-13T14:12:39Z")

</div>

Hello! I'm developing a website using Nuxt 3 and I keep getting this error on my console every time I render a page with the SliceZone component:

`Uncaught (in promise) SyntaxError: The requested module '/_nuxt/node_modules/.cache/vite/client/deps/@prismicio_client.js?v=8a196fb6' does not provide an export named 'Content'`

I think it refers to the line that's automatically added at the top of each slice setup script:

```auto
<script setup lang="ts">
import { type Content } from '@prismicio/client'
/* ... slice props */
</script>

```

Any ideas on how to fix this? This happens on every website I'm working on currently. I don't know if it's related to the fact that I **don't use typescript** in the rest of my `.vue` files (layouts, pages, components, composables).

I hope I don't have to go through every slice's `index.vue` file and remove the typescript statements, as I have already created a lot of slices. ☹

The relevant packages' versions in my `package.json` look like:

```auto
"devDependencies": {
    "@nuxt/devtools": "latest",
    "@nuxt/eslint-config": "^0.2.0",
    "@nuxtjs/eslint-module": "^4.1.0",
    "@nuxtjs/prismic": "^3.1.0",
    "@slicemachine/adapter-nuxt": "^0.3.28",
    "eslint": "^8.53.0",
    "nuxt": "^3.8.2",
    "slice-machine-ui": "^1.21.2",
    "vue": "^3.3.11",
    "vue-router": "^4.2.5"
}

```

Edit / Update: If I remove the typescript portion to a slice's `index.vue` file's setup script and leave it like so:

```auto
<script setup>
defineProps(getSliceComponentProps(['slice', 'index', 'slices', 'context']))
</script>

```

It _ **does** _ get rid of the error, if that helps further clear up the issue.

---

<div class="post-metadata">

**Author:** ![samlittlefair](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/samlittlefair/32/696_2.png) [@samlittlefair](https://community.prismic.io/u/samlittlefair)\
**Post date:** [December 15, 2023, 3:12pm UTC](https://community.prismic.io/t/slicezone-nuxt-3-error-with-type-imports-in-slices/14753/3 "2023-12-15T15:12:27Z")

</div>

Hey Daniela,

If I recall correctly, Slice Machine will automatically detect if your project is using TypeScript and then generate files accordingly. It would appear that Slice Machine is generating TypeScript files for you. Is it possible you have a tsconfig file in your project, or something else that would make Slice Machine think that you're using TypeScript? If so, try removing that and then generating a new Slice.

Sam

---

<div class="post-metadata">

**Author:** ![danyaviless18](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/danyaviless18/32/8137_2.png) [@danyaviless18](https://community.prismic.io/u/danyaviless18)\
**Post date:** [December 15, 2023, 9:32pm UTC](https://community.prismic.io/t/slicezone-nuxt-3-error-with-type-imports-in-slices/14753/5 "2023-12-15T21:32:20Z")

</div>

Thank you very much! I removed the tsconfig and it switches my /slices/index.ts to a /slices.index.js file and every new slice's setup script doesn't have the typescript snippet anymore. :) This solution works for me at the moment.

Cheers,  
Dani
