-
Notifications
You must be signed in to change notification settings - Fork 464
Open
Labels
bugSomething isn't workingSomething isn't working
Description
- version:v1.0.55
- playground demo:
转义前代码:
<template>
<el-select
v-model="selected"
clearable
></el-select>
</template>
transform.js
function transform(fileInfo, api, options) {
const $ = api.gogocode
const source = fileInfo.source
const ast = $(source, { parseOptions: { language: 'vue' } })
const template = ast.find('<template></template>')
const script = ast.find('<script></script>')
template.replace('<el-select clearable $$$1>$$$2</el-select>', '<el-select allowClear $$$1>$$$2</el-select>')
return ast.generate()
}
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working