Comments (7)
Works well in my usecase!
Also, cute ✓ addition.
from babel-plugin-transform-builtin-classes.
can we close this?
from babel-plugin-transform-builtin-classes.
Also causes a problem when using webpack. The _fixBabelExtend()
helper is only included in one of the concatenated source files. The other file, wraps the HTMLElement (in my case) with _fixBabelExtend(...)
but does not include the helper function, resulting in a Uncaught ReferenceError: _fixBabelExtend is not defined
from babel-plugin-transform-builtin-classes.
so, how are you proposing to solve this?
from babel-plugin-transform-builtin-classes.
thing is, I don't know how to always force a directive, and I thought it made sense to have the fixing code in only if native extends were used.
However, I see this as an issue but I'm not too confident with Babel internals so I'm not sure how to solve that.
from babel-plugin-transform-builtin-classes.
I know less than you about Babel plugin development, but I found this:
https://github.com/thejameskyle/babel-handbook/blob/master/translations/en/plugin-handbook.md#-pre-and-post-in-plugins
I did some initial testing, and it looks like this issue can be solved by nullifying the name
variable in the pre
-method.
return {
pre () {
name = null
},
visitor: {
ClassDeclaration(path) {
from babel-plugin-transform-builtin-classes.
can anyone please confirm v0.4 works as expected ?
Thank you @wiledal that seems to be the right way to go.
from babel-plugin-transform-builtin-classes.
Related Issues (14)
- IE11 "The custom element being constructed was not registered with 'customElements'" HOT 10
- Not working in Meteor. HOT 5
- It doesn't work in IE11 on windows 7 in combination with babel-polyfill HOT 7
- Not working with Node.js 8.9.0
- Not compatible with document-register-element for IE11 HOT 3
- Doesn't seem to work in Chrome v67 HOT 3
- path.inShadow not found (babel 7 support?) HOT 5
- Using babel-cli HOT 5
- Does not work with mixins HOT 8
- I'm using class factory mixins. HOT 14
- [feature request] support mixins HOT 4
- Providing a default set of native builtins? HOT 5
- Understanding when to use what. HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from babel-plugin-transform-builtin-classes.