Skip to content

Commit 13edb7a

Browse files
authored
fix lint (#4231)
1 parent ed89aa4 commit 13edb7a

File tree

21 files changed

+27
-34
lines changed

21 files changed

+27
-34
lines changed

.eslintrc.js

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,7 @@ module.exports = {
1414
__DEV__: true,
1515
},
1616
rules: {
17-
'no-undef': 2,
18-
'no-unreachable': 2,
19-
'no-unused-vars': 0,
20-
'no-console': 0,
17+
'no-console': 'off',
2118
semi: ['error', 'always'],
2219
quotes: ['error', 'single'],
2320
'react/jsx-uses-react': 'off', // no longer needed with new jsx transform
@@ -39,10 +36,11 @@ module.exports = {
3936
rules: {
4037
indent: ['error', 2],
4138
quotes: ['error', 'single'],
42-
'no-undef': 0,
43-
'no-constant-condition': 0,
44-
'no-useless-escape': 0,
45-
'no-dupe-keys': 0,
39+
'no-undef': 'off',
40+
'no-unused-vars': 'off',
41+
'no-constant-condition': 'off',
42+
'no-useless-escape': 'off',
43+
'no-dupe-keys': 'off',
4644
},
4745
},
4846
],

cypress/plugins/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
/**
1616
* @type {Cypress.PluginConfig}
1717
*/
18-
module.exports = (on, config) => {
18+
module.exports = () => {
1919
// `on` is used to hook into various events Cypress emits
2020
// `config` is the resolved Cypress config
2121
};

cypress/support/commands.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
const windowInnerWidth = Cypress.config('viewportWidth');
2-
const windowInnerHeight = Cypress.config('viewportHeight');
31
Cypress.Commands.add('isNotInViewport', element => {
42
cy.get(element).then($el => {
53
// we won't have horizontal scollbar

src/components/Configuration/Configuration.jsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import { Children, isValidElement } from 'react';
22
import { Details } from './components';
3-
import PropTypes from 'prop-types';
43

54
const detailComponentsList = ['link', 'mode', 'entry', 'path', 'filename', 'publicPath', 'library', 'libraryType', 'libraryName', 'advancedLibrary', 'advancedOutput', 'expertOutput', 'expertOutputB', 'expert', 'advancedConditions', 'moduleType', 'advancedActions', 'advancedModule', 'modules', 'alias', 'advancedResolve', 'expertResolve', 'hints', 'devtool', 'target', 'externals', 'externalsType', 'externalsPresets', 'ignoreWarnings', 'stats', 'preset', 'advancedGlobal', 'advancedAssets', 'advancedChunkGroups', 'advancedChunks', 'advancedModules', 'expertModules', 'advancedStatsOptimization', 'advancedOptimization', 'cacheGroupAdvancedSelectors', 'cacheGroupAdvancedEffects', 'advancedSelectors', 'advancedEffects', 'fallbackCacheGroup', 'advanced', 'advancedCaching', 'advancedBuild'];
65
export const Pre = props => {

src/components/Configuration/components.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import { isValidElement, Component } from 'react';
22
import Popover from 'react-tiny-popover';
33
import './Configuration.scss';
4-
import { timeout } from 'q';
54
import PropTypes from 'prop-types';
65

76
const DEFAULT_CHILDREN_SIZE = 4;

src/components/Cube/Cube.jsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ export default class Cube extends Component {
208208
*
209209
* @param {object} e - Native event
210210
*/
211-
_spin = e => {
211+
_spin = () => {
212212
let obj = {};
213213
let axis = this._getRandomAxis();
214214
let sign = Math.random() < 0.5 ? -1 : 1;
@@ -223,7 +223,7 @@ export default class Cube extends Component {
223223
*
224224
* @param {object} e - Native event
225225
*/
226-
_reset = e => {
226+
_reset = () => {
227227
this.setState({
228228
x: 0,
229229
y: 0,

src/components/Dropdown/Dropdown.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ export default class Dropdown extends Component {
103103
this.links[newIndex].focus();
104104
}
105105

106-
_handleClick(e) {
106+
_handleClick() {
107107
this.setState({active: !this.state.active}, () => {
108108
if (this.state.active) {
109109
this.links[0].focus();

src/components/Link/Link.jsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ export default ({
99
// mimick the `NavLink` API
1010
if ( url ) to = url;
1111

12+
// eslint-disable-next-line
1213
const {isActive, ...others} = props;
1314
if ( to.startsWith('http') || to.startsWith('//') )
1415
{

src/components/NotificationBar/NotificationBar.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ class MessageBar extends Component {
4646
*
4747
* @param {object} e - Click event
4848
*/
49-
close(e) {
49+
close() {
5050
localStorage.setItem('notification-dismissed', version);
5151
this.props.onClose();
5252
}

src/components/Organization/Organization.jsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import Shield from '../Shield/Shield';
55
import Items from './projects.json';
66
import './Organization.scss';
77

8-
const Organization = props => {
8+
const Organization = () => {
99
return (
1010
<Container className='organization page__content markdown'>
1111
<h1>The Organization</h1>

0 commit comments

Comments
 (0)