-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Closed
Labels
- P3: minor bugAn edge case that only affects very specific usage (priority)An edge case that only affects very specific usage (priority)
Description
What version of astro are you using?
1.8.0
Are you using an SSR adapter? If so, which one?
No
What package manager are you using?
npm, pnpm
What operating system are you using?
macOS 13
Describe the Bug
I have been eagerly waiting for even a beta of the Content Collections RFC to start shipping my blog. Thanks to @bholmesdev I got a chance much earlier than I could expect. I upgraded from 1.6.4(?) to 1.8.0 but I got the TS error Cannot find module 'astro:content' or its corresponding type declarations.ts(2307) when trying to import the defineCollection function.
Steps to reproduce
pnpm create astro@latestornpm create astro@latest- Create a 'content' directory and create a 'config.ts' within the folder
- Write
import { defineCollection, z } from "astro:content"within the 'config.ts'
Continuing with this state of the application leads to no errors during the build or in the dev server.
Link to Minimal Reproducible Example
https://stackblitz.com/edit/github-j2falm?file=content/config.ts
Participation
- I am willing to submit a pull request for this issue.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
- P3: minor bugAn edge case that only affects very specific usage (priority)An edge case that only affects very specific usage (priority)