mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-23 14:15:13 +00:00
fix(webpack): use javascript/auto
for js rule (#9180)
This commit is contained in:
parent
db11f7bf93
commit
7955553070
@ -62,6 +62,7 @@ exports[`webpack nuxt webpack module.rules 1`] = `
|
|||||||
Object {
|
Object {
|
||||||
\\"exclude\\": [Function exclude],
|
\\"exclude\\": [Function exclude],
|
||||||
\\"test\\": /\\\\.m?jsx?$/i,
|
\\"test\\": /\\\\.m?jsx?$/i,
|
||||||
|
\\"type\\": \\"javascript/auto\\",
|
||||||
\\"use\\": Array [
|
\\"use\\": Array [
|
||||||
Object {
|
Object {
|
||||||
\\"loader\\": \\"<nuxtDir>/node_modules/babel-loader/lib/index.js\\",
|
\\"loader\\": \\"<nuxtDir>/node_modules/babel-loader/lib/index.js\\",
|
||||||
@ -674,6 +675,7 @@ exports[`webpack nuxt webpack module.rules test=.jsx 1`] = `
|
|||||||
"Object {
|
"Object {
|
||||||
\\"exclude\\": [Function exclude],
|
\\"exclude\\": [Function exclude],
|
||||||
\\"test\\": /\\\\.m?jsx?$/i,
|
\\"test\\": /\\\\.m?jsx?$/i,
|
||||||
|
\\"type\\": \\"javascript/auto\\",
|
||||||
\\"use\\": Array [
|
\\"use\\": Array [
|
||||||
Object {
|
Object {
|
||||||
\\"loader\\": \\"<nuxtDir>/node_modules/babel-loader/lib/index.js\\",
|
\\"loader\\": \\"<nuxtDir>/node_modules/babel-loader/lib/index.js\\",
|
||||||
|
@ -330,6 +330,7 @@ export default class WebpackBaseConfig {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
test: /\.m?jsx?$/i,
|
test: /\.m?jsx?$/i,
|
||||||
|
type: 'javascript/auto',
|
||||||
exclude: (file) => {
|
exclude: (file) => {
|
||||||
file = file.split(/node_modules(.*)/)[1]
|
file = file.split(/node_modules(.*)/)[1]
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user