Sleep

1 vue-bind-once - Vue.js Supplied #.\n\nA small, SSR-safe regulation for tiing random information to an aspect.\n\nFlying start.\nTo begin with put in vue-bind-once:.\nanecdote add vue-bind-once.\n\n

or even npm.npm set up vue-bind-once-- conserve.Sign up regulation.import createApp from 'vue'.import Application from './ App.vue'.import BindOnceDirective, BindOncePlugin from 'vue-bind-once'.const app = createApp( App).app.use( BindOncePlugin).// or even app.directive(' bind-once', BindOnceDirective).In most cases you'll be using this ordinance along with an SSR-rendering framework like nuxt, which might have a various method for you to enroll this directive. For example, in a Nuxt plugin:.bring in BindOncePlugin from 'vue-bind-once'.export nonpayment defineNuxtPlugin( nuxtApp =&gt nuxtApp.vueApp.use( BindOncePlugin). ).Consumption.You may currently make use of the directive on any sort of aspect where you need a binding to a worth that requires to match between client/server however will not change dynamically after that.
This will deal with both web server and on customer re-hydration.

Articles You Can Be Interested In