Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
async function createVm() {
const source = new MockFirebase().child('data')
const vm = new Vue({
// purposely set items as null
// but it's a good practice to set it to an empty array
data: () => ({
items: [],
item: null,
}),
})
await tick()
return { vm, source }
}
beforeEach(async () => {
// @ts-ignore
collection = db.collection()
// @ts-ignore
document = db.collection().doc()
// @ts-ignore
vm = new Vue({
// purposely set items as null
// but it's a good practice to set it to an empty array
data: () => ({
items: null,
item: null,
}),
})
await tick()
})