fix(web): turn off fully specified option in webpack so packages like graphql@14 will not break build

This commit is contained in:
Jack Hsu 2021-10-14 14:50:42 -04:00 committed by Victor Savkin
parent 92ebb84c24
commit ed11e6ca73

View File

@ -58,6 +58,16 @@ export function getBaseWebpackPartial(
// Enabled for performance
unsafeCache: true,
rules: [
{
// There's an issue resolving paths without fully specified extensions
// See: https://github.com/graphql/graphql-js/issues/2721
// TODO(jack): Add a flag to turn this option on like Next.js does via experimental flag.
// See: https://github.com/vercel/next.js/pull/29880
test: /\.m?jsx?$/,
resolve: {
fullySpecified: false,
},
},
{
test: /\.([jt])sx?$/,
loader: join(__dirname, 'web-babel-loader'),