v1.2.1
New Features
Added @vue/composition-api
support, thanks to @luwanquan and @antfu.
To enable this feature, turn on the compositionAPI
flag in @vue/babel-preset-jsx
:
// babel.config.js
module.exports = {
presets: [
[
"@vue/babel-preset-jsx",
{
compositionAPI: true,
},
],
],
};
If you are using the preset provided by Vue CLI, the flag is a subfield of the jsx
option:
// babel.config.js
module.exports = {
presets: [
[
"@vue/cli-plugin-babel/preset",
{
jsx: {
compositionAPI: true,
},
},
],
],
};