diff --git a/.eslintrc.js b/.eslintrc.js index e667bb4c3f60dcd3ca876172baf2c6a9ab535b2e..36ff570d9d3cd8f10285c343b34168c18fccfe16 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,5 +1,3 @@ module.exports = { - env: { - node: true - } + extends: ['scratch', 'scratch/node'] }; diff --git a/package.json b/package.json index 440c0acbd856b667745552a7341ba75b3dc4aef9..cccb6e1d204cbc8138937d268c033b53782cf907 100644 --- a/package.json +++ b/package.json @@ -18,9 +18,6 @@ "start": "webpack-dev-server --port $npm_package_config_port --content-base=./build", "test": "npm run lint && npm run build" }, - "eslintConfig": { - "extends": ["scratch"] - }, "author": "Massachusetts Institute of Technology", "license": "BSD-3-Clause", "homepage": "https://github.com/LLK/scratch-gui#readme", @@ -40,7 +37,7 @@ "babel-preset-es2015": "6.14.0", "babel-preset-react": "6.11.1", "copy-webpack-plugin": "3.0.1", - "eslint": "3.5.0", + "eslint": "3.8.1", "eslint-config-scratch": "^2.0.0", "eslint-plugin-react": "6.4.1", "gh-pages": "0.11.0", diff --git a/src/.eslintrc.js b/src/.eslintrc.js index 95e29e0152c4a2f9cc87b33157f1bae4a8231ce8..77bf09f3fe1d42f5d7249ec84af903ec8670c28a 100644 --- a/src/.eslintrc.js +++ b/src/.eslintrc.js @@ -3,5 +3,8 @@ module.exports = { node: false, browser: true }, - extends: ['scratch/es6', 'scratch/react'] + extends: ['scratch/es6', 'scratch/react'], + globals: { + process: true + } }; diff --git a/src/components/green-flag.jsx b/src/components/green-flag.jsx index ce7b490a57a746ec1e28e36fa3def732c3d76074..21e9381a80fef0ebfe5105928259b20853f1c8fe 100644 --- a/src/components/green-flag.jsx +++ b/src/components/green-flag.jsx @@ -26,7 +26,7 @@ class GreenFlagComponent extends React.Component { GreenFlagComponent.propTypes = { onClick: React.PropTypes.func, - title: React.PropTypes.string, + title: React.PropTypes.string }; GreenFlagComponent.defaultProps = { diff --git a/src/components/library.jsx b/src/components/library.jsx index cc50b43eb02835c46cd5c4df0a7481f368cf5813..66faaa32306630b7b781acf39968d7714d3a1ba8 100644 --- a/src/components/library.jsx +++ b/src/components/library.jsx @@ -61,7 +61,7 @@ LibraryComponent.propTypes = { React.PropTypes.shape({ md5: React.PropTypes.string, name: React.PropTypes.string, - rawURL: React.PropTypes.string, + rawURL: React.PropTypes.string }) /* eslint-enable react/no-unused-prop-types, lines-around-comment */ ), diff --git a/src/components/sprite-selector.jsx b/src/components/sprite-selector.jsx index fd2807c22186fe7a0e27f4c6dada83dad6c43be1..a8384bb5622be385c60d80fd050465c96a7da853 100644 --- a/src/components/sprite-selector.jsx +++ b/src/components/sprite-selector.jsx @@ -16,7 +16,7 @@ class SpriteSelectorComponent extends React.Component { style={{ position: 'absolute', top: 380, - right: 10, + right: 10 }} {...props} > diff --git a/src/components/stage.jsx b/src/components/stage.jsx index 9f4f3a4584ef389731c43da74dee87865e7a687d..10e31209f73ecf4507bd4688a3bd9abbb60cba39 100644 --- a/src/components/stage.jsx +++ b/src/components/stage.jsx @@ -17,7 +17,7 @@ class StageComponent extends React.Component { top: 10, right: 10, width: width, - height: height, + height: height }} {...props} /> diff --git a/src/components/stop-all.jsx b/src/components/stop-all.jsx index 6b8f616bc01211d1e1efa38372e9c98ac249ca4c..be4aba6d0f78aa76f591272529b4c479f2942975 100644 --- a/src/components/stop-all.jsx +++ b/src/components/stop-all.jsx @@ -26,7 +26,7 @@ class StopAllComponent extends React.Component { StopAllComponent.propTypes = { onClick: React.PropTypes.func, - title: React.PropTypes.string, + title: React.PropTypes.string }; StopAllComponent.defaultProps = { diff --git a/src/containers/gui.jsx b/src/containers/gui.jsx index ffde713512dcf1656a74ea979936c2dc0d1bd4a7..bb44a60ca84b6c614ae6b221c67f6bbb1d0d3a9b 100644 --- a/src/containers/gui.jsx +++ b/src/containers/gui.jsx @@ -122,7 +122,7 @@ GUI.propTypes = { spriteSelectorProps: shapeFromPropTypes(SpriteSelector.propTypes, {omit: ['vm']}), stageProps: shapeFromPropTypes(Stage.propTypes, {omit: ['vm']}), stopAllProps: shapeFromPropTypes(StopAll.propTypes, {omit: ['vm']}), - vm: React.PropTypes.instanceOf(VM), + vm: React.PropTypes.instanceOf(VM) }; GUI.defaultProps = {