diff options
author | Natalia Tepluhina <ntepluhina@gitlab.com> | 2019-05-28 14:03:27 +0000 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2019-05-28 14:03:27 +0000 |
commit | ac02e496310c16debfb35c2265800dd212eb4d7f (patch) | |
tree | 3255f48327d0238d2810bc068e7ede58542d49d9 /doc/development | |
parent | fe0907970732d90b6bbb880e1a2ad3c5b7cd2d38 (diff) | |
download | gitlab-ce-ac02e496310c16debfb35c2265800dd212eb4d7f.tar.gz |
Added a note about v-slot directive
Diffstat (limited to 'doc/development')
-rw-r--r-- | doc/development/fe_guide/style_guide_js.md | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/doc/development/fe_guide/style_guide_js.md b/doc/development/fe_guide/style_guide_js.md index 060cd8baf7f..94dfdbdd073 100644 --- a/doc/development/fe_guide/style_guide_js.md +++ b/doc/development/fe_guide/style_guide_js.md @@ -544,14 +544,24 @@ Please check this [rules][eslint-plugin-vue-rules] for more documentation. <component @click="eventHandler"/> ``` -1. Shorthand `:` is preferable over `v-bind` +2. Shorthand `:` is preferable over `v-bind` ```javascript // bad <component v-bind:class="btn"/> // good - <component :class="btsn"/> + <component :class="btn"/> + ``` + +3. Shorthand `#` is preferable over `v-slot` + + ```javascript + // bad + <template v-slot:header></template> + + // good + <template #header></template> ``` #### Closing tags |