babel-plugin-transform-vue-jsx icon indicating copy to clipboard operation
babel-plugin-transform-vue-jsx copied to clipboard

syntactic sugar fails with arrow function

Open FranckFreiburger opened this issue 6 years ago • 2 comments

I have a component factory that use JSX.

export default userOptions => {
	...
	return {
		functional: true,
		render: function(h, { data, props }) {
			return <span class={...

is transformed into:

	export default { functional: true, render: (h, userOptions) ...

Without using the arrow function, everything works well.

versions: node 11.11.0 babel 7.4.0 webpack 4.29.6 vue.js 2.6.10 babel-plugin-transform-vue-jsx version: 4.0.1

FranckFreiburger avatar Mar 21 '19 11:03 FranckFreiburger

any status about this issue ?

FranckFreiburger avatar Apr 07 '19 08:04 FranckFreiburger

ping

FranckFreiburger avatar Jul 30 '19 15:07 FranckFreiburger