0👍
Moved out the uuid declaration so it’s sure it’s never reevaluated.
import Vue from 'vue'
import { nanoid } from 'nanoid'
const uuid = nanoid()
export default Vue.extend({
name: 'Identifiable',
data: () => ({
uuid
}),
})
Source:stackexchange.com