plugins: ['jest', 'import', '@typescript-eslint'],
rules: {
'no-debugger': 'error',
+ 'no-console': ['error', { allow: ['warn', 'error', 'info'] }],
// most of the codebase are expected to be env agnostic
'no-restricted-globals': ['error', ...DOMGlobals, ...NodeGlobals],
{
files: ['**/__tests__/**', 'packages/dts-test/**'],
rules: {
+ 'no-console': 'off',
'no-restricted-globals': 'off',
'no-restricted-syntax': 'off',
'jest/no-disabled-tests': 'error',
rules: {
'no-restricted-globals': ['error', ...NodeGlobals],
'no-restricted-syntax': ['error', banConstEnum],
+ 'no-console': 'off',
},
},
// JavaScript files
rules: {
'no-restricted-globals': 'off',
'no-restricted-syntax': ['error', banConstEnum],
+ 'no-console': 'off',
},
},
// Import nodejs modules in compiler-sfc
if (__DEV__ && !__TEST__ && !hasWarned) {
hasWarned = true
// @ts-expect-error `console.info` cannot be null error
+ // eslint-disable-next-line no-console
console[console.info ? 'info' : 'log'](
`<Suspense> is an experimental feature and its API will likely change.`,
)