Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: upgrade to Next.js 15 and Nextra 3 #90

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

sean-perkins
Copy link

Closes: #85, #84, #25

Upgrades the docs template to Next.js v15 and Nextra v3.

Copy link

vercel bot commented Dec 19, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
nextra-docs-template ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 23, 2024 5:21pm

@sean-perkins
Copy link
Author

If you can provide me with the Vercel logs I can take a closer look at whatever is failing in the deployment. The dev server is successful locally and the docs site builds with pnpm build.

@mavogel
Copy link

mavogel commented Dec 21, 2024

hey @sean-perkins , great work. Just came across your updates. For me locally using your sean-perkins:main branch gave me the following error:

pnpm build

> [email protected] build /Users/johndoe/developer/nextra-docs-template
> next build

(node:20762) Warning: To load an ES module, set "type": "module" in the package.json or use the .mjs extension.
(Use `node --trace-warnings ...` to show where the warning was created)
 ⨯ Failed to load next.config.js, see more info here https://nextjs.org/docs/messages/next-config-error

> Build error occurred
SyntaxError: Cannot use import statement outside a module
    at <unknown> (next.config.js:1)
 ELIFECYCLE  Command failed with exit code 1.

Checking the docs for nextra and then renaming next.config.js -> next.config.mjs fixed the dev and build. Maybe you want to give this a try and that will also fix the vercel build :)

  • node --version: v20.18.1
  • pnpm --version: 9.15.0

@sean-perkins
Copy link
Author

@mavogel thanks for the suggestion! Not sure how I overlooked that warning in the terminal.

Enabling ESModules seems to have fixed the preview deployment.

@ShrihariMohan
Copy link

looks good to me!

Copy link

@1chooo 1chooo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@weisisheng
Copy link

How long do these usually take to be merged? I am facing a new project and considering nextra if it is usable with next.js 15. TIA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update nextra-docs-template file structure & contents to match nextra@v3
5 participants