Skip to content

214132049/babel-plugin-vue-setup-return

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

babel-plugin-vue-setup-return

Babel plugin for Vue composition api

Automatic return statement injection through variable prefix for vue composition api setup

!!!note: When the function name is setup, all the matching inside the function will be converted

Usage

npm install babel-plugin-vue-setup-return --save-dev

yarn add babel-plugin-vue-setup-return --dev

In your babel.config.js:

plugins: [
  [
    'vue-setup-return', {
      prefix: '_RE_'  // prefix defult __RE__
    }
  ]
]

example

Refer to this project test folder: index.test.js

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Packages