Skip to content

Commit 309480d

Browse files
MachinisteWebchrisvfritz
authored andcommitted
render-function.md — tick consistency (#956)
* Add french translation link Signed-off-by: Bruno Lesieur <bruno.lesieur@gmail.com> * kebab-case explaination updates Signed-off-by: Bruno Lesieur <bruno.lesieur@gmail.com> * kebab-case to kebab-cased Signed-off-by: Bruno Lesieur <bruno.lesieur@gmail.com> * Remove space before self-closing component * Add some tick for consistency Signed-off-by: Bruno Lesieur <bruno.lesieur@gmail.com>
1 parent e19076d commit 309480d

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

src/v2/guide/render-function.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ createElement(
106106
},
107107

108108
// {String | Array}
109-
// Children VNodes, built using createElement(),
109+
// Children VNodes, built using `createElement()`,
110110
// or simply using strings to get 'text VNodes'. Optional.
111111
[
112112
'Some text comes first.',
@@ -148,16 +148,16 @@ One thing to note: similar to how `v-bind:class` and `v-bind:style` have special
148148
domProps: {
149149
innerHTML: 'baz'
150150
},
151-
// Event handlers are nested under "on", though
152-
// modifiers such as in v-on:keyup.enter are not
151+
// Event handlers are nested under `on`, though
152+
// modifiers such as in `v-on:keyup.enter` are not
153153
// supported. You'll have to manually check the
154154
// keyCode in the handler instead.
155155
on: {
156156
click: this.clickHandler
157157
},
158158
// For components only. Allows you to listen to
159159
// native events, rather than events emitted from
160-
// the component using vm.$emit.
160+
// the component using `vm.$emit`.
161161
nativeOn: {
162162
click: this.nativeClickHandler
163163
},
@@ -366,7 +366,7 @@ You can access static slot contents as Arrays of VNodes from [`this.$slots`](../
366366

367367
``` js
368368
render: function (createElement) {
369-
// <div><slot></slot></div>
369+
// `<div><slot></slot></div>`
370370
return createElement('div', this.$slots.default)
371371
}
372372
```
@@ -375,7 +375,7 @@ And access scoped slots as functions that return VNodes from [`this.$scopedSlots
375375

376376
``` js
377377
render: function (createElement) {
378-
// <div><slot :text="msg"></slot></div>
378+
// `<div><slot :text="msg"></slot></div>`
379379
return createElement('div', [
380380
this.$scopedSlots.default({
381381
text: this.msg
@@ -390,7 +390,7 @@ To pass scoped slots to a child component using render functions, use the `scope
390390
render (createElement) {
391391
return createElement('div', [
392392
createElement('child', {
393-
// pass scopedSlots in the data object
393+
// pass `scopedSlots` in the data object
394394
// in the form of { name: props => VNode | Array<VNode> }
395395
scopedSlots: {
396396
default: function (props) {

0 commit comments

Comments
 (0)