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

Next.js 14.0.0 /pages app: SpeedInsights import causes breaking changes #37

Closed
aydangoon opened this issue Jan 6, 2024 · 1 comment
Closed

Comments

@aydangoon
Copy link

When we try and import SpeedInsights component in our /pages/_app.tsx file and deploy through vercel, all pages return the error

file:///var/task/node_modules/@vercel/speed-insights/dist/next/index.mjs:4
import React, { Suspense } from "react";
                ^^^^^^^^
SyntaxError: Named export 'Suspense' not found.

In our package.json:

    "@vercel/speed-insights": "1.0.3",
    "next": "14.0.0",
    "react": "^18",
    "react-dom": "^18",
     ...
@aydangoon
Copy link
Author

This was a bug in next that was patched in 14.0.4. After migrating everything works!

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

No branches or pull requests

1 participant