From 69ceb7384b6218ff185f479c8525ca792cad0d00 Mon Sep 17 00:00:00 2001
From: Gabriel Ricard <4550801+gricard@users.noreply.github.com>
Date: Thu, 30 Nov 2017 06:52:30 -0500
Subject: [PATCH] Converted to create-react-app Upgraded to react 16, etc.
---
.babelrc | 8 -
.editorconfig | 2 +-
.eslintrc | 69 -
.gitignore | 22 +-
README-CRA.md | 2229 ++++++
README.md | 12 +-
TODO.txt | 28 -
package.json | 104 +-
public/favicon.ico | Bin 0 -> 3870 bytes
public/index.html | 40 +
public/manifest.json | 15 +
src/actions/actionTypes.js | 34 +-
src/actions/ajaxStatusActions.js | 7 +-
src/actions/authorActions.js | 46 +-
src/actions/courseActions.js | 71 +-
src/actions/courseActions.test.js | 92 +-
src/api/mockAuthorApi.js | 130 +-
src/api/mockCourseApi.js | 181 +-
src/components/App.js | 49 +-
src/components/about/AboutPage.js | 7 +-
.../author/AuthorForm.Enzyme.test.js | 53 +-
src/components/author/AuthorForm.js | 46 +-
src/components/author/AuthorList.js | 15 +-
src/components/author/AuthorListRow.js | 15 +-
src/components/author/AuthorsPage.js | 40 +-
src/components/author/ManageAuthorPage.js | 63 +-
.../author/ManageAuthorPage.test.js | 39 +-
src/components/author/RouteAuthorManage.js | 13 +
src/components/common/Header.js | 45 +-
src/components/common/LoadingDots.js | 64 +-
src/components/common/Main.js | 32 +
src/components/common/NotFoundPage.js | 2 +-
src/components/common/SelectInput.js | 71 +-
src/components/common/TextInput.js | 56 +-
.../course/CourseForm.Enzyme.test.js | 85 +-
.../course/CourseForm.ReactTestUtils.test.js | 43 -
src/components/course/CourseForm.js | 65 +-
src/components/course/CourseList.js | 19 +-
src/components/course/CourseListRow.js | 28 +-
src/components/course/CoursesPage.js | 45 +-
src/components/course/ManageCoursePage.js | 165 +-
.../course/ManageCoursePage.test.js | 48 +-
src/components/course/RouteCourseManage.js | 13 +
src/components/home/HomePage.js | 13 +-
src/index.html | 10 -
src/index.js | 31 +-
src/index.test.js | 6 +-
src/reducers/ajaxStatusReducer.js | 19 +-
src/reducers/authorReducer.js | 9 +-
src/reducers/courseReducer.js | 10 +-
src/reducers/courseReducer.test.js | 90 +-
src/reducers/index.js | 10 +-
src/reducers/initialState.js | 2 +-
src/routes.js | 24 -
src/selectors/selectors.js | 2 +-
src/selectors/selectors.test.js | 17 +-
src/store/configureStore.dev.js | 10 +-
src/store/configureStore.js | 6 +-
src/store/configureStore.prod.js | 12 +-
src/store/store.test.js | 43 +-
src/styles/styles.css | 14 +-
tools/build.js | 35 -
tools/buildHtml.js | 26 -
tools/distServer.js | 24 -
tools/srcServer.js | 30 -
tools/startMessage.js | 5 -
tools/testSetup.js | 51 -
webpack.config.dev.js | 36 -
webpack.config.prod.js | 40 -
yarn.lock | 6917 +++++++++++++++++
70 files changed, 10334 insertions(+), 1369 deletions(-)
delete mode 100644 .babelrc
delete mode 100644 .eslintrc
create mode 100644 README-CRA.md
delete mode 100644 TODO.txt
create mode 100644 public/favicon.ico
create mode 100644 public/index.html
create mode 100644 public/manifest.json
create mode 100644 src/components/author/RouteAuthorManage.js
create mode 100644 src/components/common/Main.js
delete mode 100644 src/components/course/CourseForm.ReactTestUtils.test.js
create mode 100644 src/components/course/RouteCourseManage.js
delete mode 100644 src/index.html
delete mode 100644 src/routes.js
delete mode 100644 tools/build.js
delete mode 100644 tools/buildHtml.js
delete mode 100644 tools/distServer.js
delete mode 100644 tools/srcServer.js
delete mode 100644 tools/startMessage.js
delete mode 100644 tools/testSetup.js
delete mode 100644 webpack.config.dev.js
delete mode 100644 webpack.config.prod.js
create mode 100644 yarn.lock
diff --git a/.babelrc b/.babelrc
deleted file mode 100644
index c8e2dc5..0000000
--- a/.babelrc
+++ /dev/null
@@ -1,8 +0,0 @@
-{
- "presets": ["react", "es2015"],
- "env": {
- "development": {
- "presets": ["react-hmre"]
- }
- }
-}
diff --git a/.editorconfig b/.editorconfig
index 5d12634..e9a9bff 100644
--- a/.editorconfig
+++ b/.editorconfig
@@ -3,7 +3,7 @@ root = true
[*]
indent_style = space
-indent_size = 2
+indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
diff --git a/.eslintrc b/.eslintrc
deleted file mode 100644
index b37951e..0000000
--- a/.eslintrc
+++ /dev/null
@@ -1,69 +0,0 @@
-{
- "extends": [
- "eslint:recommended",
- "plugin:import/errors",
- "plugin:import/warnings"
- ],
- "plugins": [
- "react"
- ],
- "parserOptions": {
- "ecmaVersion": 6,
- "sourceType": "module",
- "ecmaFeatures": {
- "jsx": true
- }
- },
- "env": {
- "es6": true,
- "browser": true,
- "node": true,
- "jquery": true,
- "mocha": true
- },
- "rules": {
- "quotes": 0,
- "no-console": 1,
- "no-debugger": 1,
- "no-var": 1,
- "semi": [1, "always"],
- "no-trailing-spaces": 0,
- "eol-last": 0,
- "no-unused-vars": 0,
- "no-underscore-dangle": 0,
- "no-alert": 0,
- "no-lone-blocks": 0,
- "jsx-quotes": 1,
- "react/display-name": [ 1, {"ignoreTranspilerName": false }],
- "react/forbid-prop-types": [1, {"forbid": ["any"]}],
- "react/jsx-boolean-value": 1,
- "react/jsx-closing-bracket-location": 0,
- "react/jsx-curly-spacing": 1,
- "react/jsx-indent-props": 0,
- "react/jsx-key": 1,
- "react/jsx-max-props-per-line": 0,
- "react/jsx-no-bind": 1,
- "react/jsx-no-duplicate-props": 1,
- "react/jsx-no-literals": 0,
- "react/jsx-no-undef": 1,
- "react/jsx-pascal-case": 1,
- "react/jsx-sort-prop-types": 0,
- "react/jsx-sort-props": 0,
- "react/jsx-uses-react": 1,
- "react/jsx-uses-vars": 1,
- "react/no-danger": 1,
- "react/no-did-mount-set-state": 1,
- "react/no-did-update-set-state": 1,
- "react/no-direct-mutation-state": 1,
- "react/no-multi-comp": 1,
- "react/no-set-state": 0,
- "react/no-unknown-property": 1,
- "react/prefer-es6-class": 1,
- "react/prop-types": 1,
- "react/react-in-jsx-scope": 1,
- "import/extensions": 1,
- "react/self-closing-comp": 1,
- "react/sort-comp": 1,
- "react/jsx-wrap-multilines": 1
- }
-}
diff --git a/.gitignore b/.gitignore
index 75d7f5f..d30f40e 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,21 @@
+# See https://help.github.com/ignore-files/ for more about ignoring files.
+
+# dependencies
/node_modules
-/.idea
-/dist
+
+# testing
+/coverage
+
+# production
+/build
+
+# misc
+.DS_Store
+.env.local
+.env.development.local
+.env.test.local
+.env.production.local
+
+npm-debug.log*
+yarn-debug.log*
+yarn-error.log*
diff --git a/README-CRA.md b/README-CRA.md
new file mode 100644
index 0000000..b8c0b74
--- /dev/null
+++ b/README-CRA.md
@@ -0,0 +1,2229 @@
+This project was bootstrapped with [Create React App](https://github.com/facebookincubator/create-react-app).
+
+Below you will find some information on how to perform common tasks.
+You can find the most recent version of this guide [here](https://github.com/facebookincubator/create-react-app/blob/master/packages/react-scripts/template/README.md).
+
+## Table of Contents
+
+- [Updating to New Releases](#updating-to-new-releases)
+- [Sending Feedback](#sending-feedback)
+- [Folder Structure](#folder-structure)
+- [Available Scripts](#available-scripts)
+ - [npm start](#npm-start)
+ - [npm test](#npm-test)
+ - [npm run build](#npm-run-build)
+ - [npm run eject](#npm-run-eject)
+- [Supported Language Features and Polyfills](#supported-language-features-and-polyfills)
+- [Syntax Highlighting in the Editor](#syntax-highlighting-in-the-editor)
+- [Displaying Lint Output in the Editor](#displaying-lint-output-in-the-editor)
+- [Debugging in the Editor](#debugging-in-the-editor)
+- [Formatting Code Automatically](#formatting-code-automatically)
+- [Changing the Page `