diff options
author | Winnie Hellmann <winnie@gitlab.com> | 2018-05-04 07:42:44 +0000 |
---|---|---|
committer | Winnie Hellmann <winnie@gitlab.com> | 2018-05-04 07:42:44 +0000 |
commit | 7f107539ab78c120b99c10570ccc5301c14c035f (patch) | |
tree | 15ad2292f28a712d4ceb024eba4f4ced3ebc3731 | |
parent | 31fa96960f7d224a1da4ca1cf1520a657558567d (diff) | |
download | gitlab-ce-7f107539ab78c120b99c10570ccc5301c14c035f.tar.gz |
Clarify location of Vue templates
-rw-r--r-- | doc/development/fe_guide/style_guide_js.md | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/doc/development/fe_guide/style_guide_js.md b/doc/development/fe_guide/style_guide_js.md index 677168937c7..04dfe418dbe 100644 --- a/doc/development/fe_guide/style_guide_js.md +++ b/doc/development/fe_guide/style_guide_js.md @@ -310,7 +310,7 @@ Please check this [rules][eslint-plugin-vue-rules] for more documentation. })); ``` -1. Don not use a singleton for the service or the store +1. Do not use a singleton for the service or the store ```javascript // bad class Store { @@ -328,9 +328,11 @@ Please check this [rules][eslint-plugin-vue-rules] for more documentation. } } ``` +1. Use `.vue` for Vue templates. Do not use `%template` in HAML. #### Naming -1. **Extensions**: Use `.vue` extension for Vue components. + +1. **Extensions**: Use `.vue` extension for Vue components. Do not use `.js` as file extension ([#34371]). 1. **Reference Naming**: Use PascalCase for their instances: ```javascript // bad @@ -364,6 +366,8 @@ Please check this [rules][eslint-plugin-vue-rules] for more documentation. <component my-prop="prop" /> ``` +[#34371]: https://gitlab.com/gitlab-org/gitlab-ce/issues/34371 + #### Alignment 1. Follow these alignment styles for the template method: 1. With more than one attribute, all attributes should be on a new line: |