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

Ensure flight manifest is correct with app and pages dir #38716

Merged
merged 1 commit into from Jul 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -79,6 +79,12 @@ export class FlightManifestPlugin {
id: string | number,
mod: any
) {
// if appDir is enabled we shouldn't process chunks from
// the pages dir
if (chunk.name?.startsWith('pages/') && appDir) {
return
}

const isCSSModule =
mod.type === 'css/mini-extract' ||
(mod.loaders &&
Expand Down
5 changes: 5 additions & 0 deletions packages/react-dev-overlay/src/internal/ErrorBoundary.tsx
Expand Up @@ -12,6 +12,11 @@ class ErrorBoundary extends React.PureComponent<
ErrorBoundaryState
> {
state = { error: null }

static getDerivedStateFromError(error: Error) {
return { error }
}

componentDidCatch(
error: Error,
// Loosely typed because it depends on the React version and was
Expand Down