babel-plugin-transform-custom-element-classes
babel-plugin-transform-custom-element-classes copied to clipboard
Add this behavior to Babel
I spoke with @hzoo at the recent Chrome Dev Summit afterparty about this issue, and we discussed updating the behavior in Babel to call Reflect.construct when extending exotic things like HTMLElement.
I was wondering if the maintainers of this project would be interested in helping put together a PR to explore updating Babel's behavior?
cc @owencm @justinfagnani
FWIW, I strongly support this as a way to fix https://github.com/facebookincubator/create-react-app/issues/3225
It may just be me but, I've never actually been able to get this plugin to work.
@treshugart I put together a simple vanilla element and example and it seems to be working OK. Do you happen to have a reproducible test case where it breaks?
Would love to deprecate this repository if this feature is upstreamed.
is anyone familiar enough with the Babel codebase to do the upstreaming work...? 😁 cc @justinfagnani, @fredkschott
Can do a call to go over things if it's helpful. https://github.com/babel/babel/issues/4480#issuecomment-351056130 some people are really excited for this kind of thing + https://github.com/WebReflection/babel-plugin-transform-builtin-classes
Ok @nicolo-ribaudo started a PR so maybe everyone can help review if it covers the same behavior as this plugin. https://github.com/babel/babel/pull/7020
Hey @robdodson, I think I was just being a dummy. I was using it on the consuming end as opposed to building Skate with it (IIRC). See comment here. Looks like there's plans for this to go into Skate as well.
Hi everyone,
Can someone confirm if the behavior of this plugin is covered by https://github.com/babel/babel/pull/7020 or not?
I don't want to block that PR on this, but I can look to port this plugin in @babel/plugin-transform-classes if the other Babel team members agree.