Skip to content
This repository has been archived by the owner on Jan 26, 2019. It is now read-only.

Disable navigationFallback and navigationFallbackWhitelist in prod webpack config by default. #455

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 4 additions & 5 deletions config/webpack.config.prod.js
Original file line number Diff line number Diff line change
Expand Up @@ -368,13 +368,12 @@ module.exports = {
console.log(message);
},
minify: true,
// For unknown URLs, fallback to the index page
navigateFallback: publicUrl + '/index.html',
// Ignores URLs starting from /__ (useful for Firebase):
// https://github.com/facebookincubator/create-react-app/issues/2237#issuecomment-302693219
navigateFallbackWhitelist: [/^(?!\/__).*/],
// Don't precache sourcemaps (they're large) and build asset manifest:
staticFileGlobsIgnorePatterns: [/\.map$/, /asset-manifest\.json$/],
// `navigateFallback` and `navigateFallbackWhitelist` are disabled by default; see
// https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md#service-worker-considerations
// navigateFallback: publicUrl + '/index.html',
// navigateFallbackWhitelist: [/^(?!\/__).*/],
}),
// Moment.js is an extremely popular library that bundles large locale files
// by default due to how Webpack interprets its code. This is a practical
Expand Down