Go back to Examples

v-once

Versoly Attributes - Advanced

v-once is used for SEO. Elements with v-scope aren't rendered statically, however if the element or its parent include v-once it will render statically.

                <!-- Code Editor -->
<div v-scope="">
    <template v-for="post in posts" v-once="">
        <h1 v-html="post.name"></h1>
    </template>
</div>

<!-- Published Code -->
<h1>Post 1</h1>
<h1>Post 2</h1>
<h1>Post 3</h1>