Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
test('.lazy', () => {
const root = transformWithModel('<input>')
expect(generate(root).code).toMatchSnapshot()
})
})
test('simple expression', () => {
const ast = transformWithShow(`<div>`)
expect(generate(ast).code).toMatchSnapshot()
})
</div>
function compileWithSrcset(template: string) {
const ast = baseParse(template)
transform(ast, {
nodeTransforms: [transformSrcset, transformElement],
directiveTransforms: {
bind: transformBind
}
})
return generate(ast, { mode: 'module' })
}
function compileWithAssetUrls(template: string) {
const ast = baseParse(template)
transform(ast, {
nodeTransforms: [transformAssetUrl, transformElement],
directiveTransforms: {
bind: transformBind
}
})
return generate(ast, { mode: 'module' })
}