-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Feedback: using _app.mdx vs _app.tsx is weird and more error prone #1632
Comments
Please provide your reproduction of weird behavior with _app.mdx |
This is not a bug report; rather just general feedback. As for a repro:
|
You can't just declare variables (you must to use |
Thanks @B2o5T. Removing the TS types from the mdx file makes the build work. My original feedback still stands, however. I'd greatly prefer to use Really appreciate the quick response btw – thanks for all your hard work! 🙏 💕 |
We'll try to improve it in Nextra 3 |
Thanks @B2o5T 🙏 |
One more point to allow |
I got my use case working with
_app.tsx
, but after #1448, the guidance and console logs tell you to use_app.mdx
.This feels really weird to me as an end user. I tried using
_app.mdx
and kept running into weird transpilation issues, and all existing docs and examples from the greater Next.js ecosystem use_app.tsx
.For context, I'm not using
mdx
at all for https://sklearn.vercel.app (solelymd
).My recommendation would be to find a way to have
_app.tsx
/_document.tsx
be the default methods for injecting custom JS/TS.The text was updated successfully, but these errors were encountered: