Skip to content

Commit dadf93b

Browse files
authored
Disable require.ensure() warning (#2177)
1 parent 66792dd commit dadf93b

File tree

1 file changed

+7
-5
lines changed
  • packages/eslint-config-react-app

1 file changed

+7
-5
lines changed

packages/eslint-config-react-app/index.js

+7-5
Original file line numberDiff line numberDiff line change
@@ -220,11 +220,13 @@ module.exports = {
220220
'valid-typeof': 'warn',
221221
'no-restricted-properties': [
222222
'error',
223-
{
224-
object: 'require',
225-
property: 'ensure',
226-
message: 'Please use import() instead. More info: https://webpack.js.org/guides/code-splitting-import/#dynamic-import',
227-
},
223+
// TODO: reenable once import() is no longer slow.
224+
// https://github.com/facebookincubator/create-react-app/issues/2176
225+
// {
226+
// object: 'require',
227+
// property: 'ensure',
228+
// message: 'Please use import() instead. More info: https://webpack.js.org/guides/code-splitting-import/#dynamic-import',
229+
// },
228230
{
229231
object: 'System',
230232
property: 'import',

0 commit comments

Comments
 (0)