Skip to content
Closed
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/guide/component-custom-events.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

> This page assumes you've already read the [Components Basics](component-basics.md). Read that first if you are new to components.

<div class="vueschool"><a href="https://vueschool.io/lessons/communication-between-components?friend=vuejs" target="_blank" rel="sponsored noopener" title="Learn how to work with custom events on Vue School">Learn how to work with custom events in a free Vue School lesson</a></div>

## Event Names

Unlike components and props, event names don't provide any automatic case transformation. Instead, the name of an emitted event must exactly match the name used to listen to that event. For example, if emitting a camelCased event name:
Expand Down
2 changes: 2 additions & 0 deletions src/guide/component-props.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

> This page assumes you've already read the [Components Basics](component-basics.md). Read that first if you are new to components.

<div class="vueschool"><a href="https://vueschool.io/lessons/reusable-components-with-props?friend=vuejs" target="_blank" rel="sponsored noopener" title="Learn how component props work with Vue School">Learn how component props work with a free lesson on Vue School</a></div>

## Prop Types

So far, we've only seen props listed as an array of strings:
Expand Down
2 changes: 2 additions & 0 deletions src/guide/computed.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

## Computed Properties

<div class="vueschool"><a href="https://vueschool.io/lessons/vuejs-computed-properties?friend=vuejs" target="_blank" rel="sponsored noopener" title="Learn how computed properties work with Vue School">Learn how computed properties work with a free lesson on Vue School</a></div>

In-template expressions are very convenient, but they are meant for simple operations. Putting too much logic in your templates can make them bloated and hard to maintain. For example, if we have an object with a nested array:

```js
Expand Down
2 changes: 2 additions & 0 deletions src/guide/conditional.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# Conditional Rendering

<div class="vueschool"><a href="https://vueschool.io/lessons/vuejs-conditionals?friend=vuejs" target="_blank" rel="sponsored noopener" title="Learn how conditional rendering works with Vue School">Learn how conditional rendering works with a free lesson on Vue School</a></div>

## `v-if`

The directive `v-if` is used to conditionally render a block. The block will only be rendered if the directive's expression returns a truthy value.
Expand Down
2 changes: 2 additions & 0 deletions src/guide/list.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# List Rendering

<div class="vueschool"><a href="https://vueschool.io/lessons/vuejs-loops?friend=vuejs" target="_blank" rel="sponsored noopener" title="Learn how to render lists on Vue School">Learn how to render list with a free Vue School lesson</a></div>

## Mapping an Array to Elements with `v-for`

We can use the `v-for` directive to render a list of items based on an array. The `v-for` directive requires a special syntax in the form of `item in items`, where `items` is the source data array and `item` is an **alias** for the array element being iterated on:
Expand Down