diff --git a/.eslintrc.js b/.eslintrc.js index 61c66f6..ac090cc 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -8,7 +8,7 @@ module.exports = { semi: ["error", "never"], "arrow-parens": ["error", "as-needed"], "react/jsx-filename-extension": ["warn", { "extensions": [".js"] }], - "react/prop-types": "warn", + "react/prop-types": "error", "jsx-a11y/label-has-for": ["error", { "components": ["Label"], "required": { diff --git a/package.json b/package.json index d4acb7c..cbaa096 100644 --- a/package.json +++ b/package.json @@ -5,11 +5,11 @@ "homepage": "https://tatomyr.github.io/estimate-it/", "scripts": { "start": "react-scripts start", - "build": "react-scripts build && npm run analyze", + "build": "react-scripts build", "lint": "eslint src/", "test": "react-scripts test --env=jsdom --coverage", - "precommit": "npm run lint && npm run test", - "predeploy": "npm run build", + "precommit": "git status && npm run lint && npm run test", + "predeploy": "npm run build && npm run analyze", "deploy": "gh-pages -d build", "analyze": "source-map-explorer build/static/js/main.*", "eject": "react-scripts eject" diff --git a/src/components/App.js b/src/components/App.js new file mode 100644 index 0000000..842882f --- /dev/null +++ b/src/components/App.js @@ -0,0 +1,32 @@ +import React from 'react' +import { Switch } from 'react-router-dom' +import Route from './ProtectedRoute' +import Home from './Home' +import Private from './Private' +import Redirector from './Redirector' +import Estimate from './Estimate' +import Dashboard from './Dashboard' +import AuthScreen from './AuthScreen' +import Spinner from './Spinner' +import Toastr from './Toastr' + +const App = () => ( +