diff options
Diffstat (limited to 'doc/development')
-rw-r--r-- | doc/development/frontend.md | 16 | ||||
-rw-r--r-- | doc/development/testing.md | 4 |
2 files changed, 6 insertions, 14 deletions
diff --git a/doc/development/frontend.md b/doc/development/frontend.md index 75fdf3d8e63..d42922d5752 100644 --- a/doc/development/frontend.md +++ b/doc/development/frontend.md @@ -33,13 +33,13 @@ you can find a clear separation of concerns: ``` new_feature ├── components -│ └── component.js.es6 +│ └── component.js │ └── ... ├── store -│ └── new_feature_store.js.es6 +│ └── new_feature_store.js ├── service -│ └── new_feature_service.js.es6 -├── new_feature_bundle.js.es6 +│ └── new_feature_service.js +├── new_feature_bundle.js ``` _For consistency purposes, we recommend you to follow the same structure._ @@ -367,14 +367,6 @@ For our currently-supported browsers, see our [requirements][requirements]. ## Gotchas -### Spec errors due to use of ES6 features in `.js` files - -If you see very generic JavaScript errors (e.g. `jQuery is undefined`) being -thrown in Teaspoon, Spinach, or Rspec tests but can't reproduce them manually, -you may have included `ES6`-style JavaScript in files that don't have the -`.js.es6` file extension. Either use ES5-friendly JavaScript or rename the file -you're working in (`git mv <file.js> <file.js.es6>`). - ### Spec errors due to use of unsupported JavaScript Similar errors will be thrown if you're using JavaScript features not yet diff --git a/doc/development/testing.md b/doc/development/testing.md index dbea6b9c9aa..bcd9524b6a0 100644 --- a/doc/development/testing.md +++ b/doc/development/testing.md @@ -36,8 +36,8 @@ the command line via `bundle exec teaspoon`, or via a web browser at `http://localhost:3000/teaspoon` when the Rails server is running. - JavaScript tests live in `spec/javascripts/`, matching the folder structure of - `app/assets/javascripts/`: `app/assets/javascripts/behaviors/autosize.js.es6` has a corresponding - `spec/javascripts/behaviors/autosize_spec.js.es6` file. + `app/assets/javascripts/`: `app/assets/javascripts/behaviors/autosize.js` has a corresponding + `spec/javascripts/behaviors/autosize_spec.js` file. - Haml fixtures required for JavaScript tests live in `spec/javascripts/fixtures`. They should contain the bare minimum amount of markup necessary for the test. |