diff --git a/src/v2/guide/render-function.md b/src/v2/guide/render-function.md index 762ba66903..c0f9ef4080 100644 --- a/src/v2/guide/render-function.md +++ b/src/v2/guide/render-function.md @@ -106,7 +106,7 @@ createElement( }, // {String | Array} - // Children VNodes, built using createElement(), + // Children VNodes, built using `createElement()`, // or simply using strings to get 'text VNodes'. Optional. [ 'Some text comes first.', @@ -148,8 +148,8 @@ One thing to note: similar to how `v-bind:class` and `v-bind:style` have special domProps: { innerHTML: 'baz' }, - // Event handlers are nested under "on", though - // modifiers such as in v-on:keyup.enter are not + // Event handlers are nested under `on`, though + // modifiers such as in `v-on:keyup.enter` are not // supported. You'll have to manually check the // keyCode in the handler instead. on: { @@ -157,7 +157,7 @@ One thing to note: similar to how `v-bind:class` and `v-bind:style` have special }, // For components only. Allows you to listen to // native events, rather than events emitted from - // the component using vm.$emit. + // the component using `vm.$emit`. nativeOn: { click: this.nativeClickHandler }, @@ -366,7 +366,7 @@ You can access static slot contents as Arrays of VNodes from [`this.$slots`](../ ``` js render: function (createElement) { - //
+ // `
` return createElement('div', this.$slots.default) } ``` @@ -375,7 +375,7 @@ And access scoped slots as functions that return VNodes from [`this.$scopedSlots ``` js render: function (createElement) { - //
+ // `
` return createElement('div', [ this.$scopedSlots.default({ text: this.msg @@ -390,7 +390,7 @@ To pass scoped slots to a child component using render functions, use the `scope render (createElement) { return createElement('div', [ createElement('child', { - // pass scopedSlots in the data object + // pass `scopedSlots` in the data object // in the form of { name: props => VNode | Array } scopedSlots: { default: function (props) {