https://github.com/chrisweb/cannot_access_frontmatter_before_initialization
https://github.com/chrisweb/cannot_access_frontmatter_before_initialization
Last synced: over 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/chrisweb/cannot_access_frontmatter_before_initialization
- Owner: chrisweb
- Created: 2025-03-24T10:35:31.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-03-24T11:07:40.000Z (over 1 year ago)
- Last Synced: 2025-03-24T12:26:10.615Z (over 1 year ago)
- Language: TypeScript
- Size: 74.2 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ReferenceError: Cannot access 'frontmatter' before initialization
Investigating a problem that might be related to [remark-mdx-frontmatter](https://github.com/remcohaszing/remark-mdx-frontmatter/issues/17) (not confirmed yet)
```shell
⨯ ReferenceError: Cannot access 'frontmatter' before initialization
at eval (app\page.mdx:7:11)
at (rsc)/./app/page.mdx (C:\Users\chris\grepos\cannot_access_frontmatter_before_initialization\.next\server\app\page.js:44:1)
at Function.__webpack_require__ (C:\Users\chris\grepos\cannot_access_frontmatter_before_initialization\.next\server\webpack-runtime.js:33:42) {
page: '/'
}
```
ticket on github:
## reproduction
install the dependencies:
```shell
npm i
```
run the development server:
```shell
npm run dev
```
visit localhost:3000 in your browser
> [!IMPORTANT]
> when installing different versions of packages, after each update make sure to delete the next.js cache