Skip to content

Commit

Permalink
Client code cleanup: re-organize file structure, set up prettier (#917)
Browse files Browse the repository at this point in the history
* Client code cleanup: re-organize file structure, set up prettier

* Fix linting

* More lint fixes

* Fix bugs

* Delete separate client README, already captured in Wiki

* Fix broken tests, add React tests to Circle build

* Update flow packages and fix errors

* Fix multiple babel-polyfill injections

* Don't run prettier in Circle builds
  • Loading branch information
julianguyen committed Jul 23, 2018
1 parent 3be271c commit 11dfaac
Show file tree
Hide file tree
Showing 106 changed files with 3,033 additions and 2,988 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
/config/env/development.env

# Ignore all IDE, TextEditor configuration files
.vs/
.idea/
.tags
*.swp
Expand Down
5 changes: 3 additions & 2 deletions circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,19 +17,20 @@ dependencies:
override:
- gem install bundler
- bundle install --path=vendor/bundle --jobs=4 --retry=3
- yarn
- yarn install

test:
pre:
- RAILS_ENV=test bundle exec rake db:create db:schema:load
- cd client &&
RAILS_ENV=test bundle exec rake react_on_rails:locale &&
yarn run lint:setup && yarn run lint && yarn run build:test
yarn lint:setup && yarn lint:build && yarn build:test
override:
- bundle exec rspec --format progress --format RspecJunitFormatter -o
$CIRCLE_TEST_REPORTS/rspec.xml
- RAILS_ENV=test bundle exec rake jasmine:ci
- bundle exec bundle-audit check --update
- cd client && yarn test

deployment:
staging:
Expand Down
4 changes: 2 additions & 2 deletions client/.eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
},
"root": true,
"rules": {
"import/prefer-default-export": ["off"],
"react/require-default-props": ["off"],
"react/sort-comp": [2, {
"order": [
"type-annotations",
Expand All @@ -24,9 +26,7 @@
"import/resolver": {
"node": {
"paths": [
// allow absolute import from "app/libs/.." as "libs/.."
"./app",
// allow absolute import from "../configs/locales.." as "configs/locales.."
".."
]
}
Expand Down
4 changes: 4 additions & 0 deletions client/.prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"trailingComma": "es5",
"singleQuote": true
}
47 changes: 0 additions & 47 deletions client/README.md

This file was deleted.

37 changes: 0 additions & 37 deletions client/app/bundles/momentsApp/components/Chart/Chart.jsx

This file was deleted.

This file was deleted.

2 changes: 0 additions & 2 deletions client/app/bundles/momentsApp/components/Chart/index.js

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Loading

0 comments on commit 11dfaac

Please sign in to comment.