Update infrastructure to use microbundle and karmatic#9
Update infrastructure to use microbundle and karmatic#9developit merged 7 commits intodevelopit:masterfrom
Conversation
|
Hmm it seems that The following code snippet repros the error I see in our build: > const NodentCompiler = require('nodent-compiler');
undefined
> const compiler = new NodentCompiler();
undefined
> compiler.compile('function f({ a, b, ...extra }) { console.log(a, b, extra); }', 'test')
TypeError: Cannot read property 'type' of undefined
at Object.Property (D:\github\andrewiggins\preact-transition-group\node_modules\nodent-compiler\output.js:691:55)
at Object.out (D:\github\andrewiggins\preact-transition-group\node_modules\nodent-compiler\output.js:125:11)
at ObjectPattern (D:\github\andrewiggins\preact-transition-group\node_modules\nodent-compiler\output.js:703:22)
at Object.out (D:\github\andrewiggins\preact-transition-group\node_modules\nodent-compiler\output.js:125:11)
at Object.formatParameters (D:\github\andrewiggins\preact-transition-group\node_modules\nodent-compiler\output.js:146:14)
at Object.Function (D:\github\andrewiggins\preact-transition-group\node_modules\nodent-compiler\output.js:404:14)
at Object.FunctionDeclaration (D:\github\andrewiggins\preact-transition-group\node_modules\nodent-compiler\output.js:408:14)
at Object.out (D:\github\andrewiggins\preact-transition-group\node_modules\nodent-compiler\output.js:125:11)
at Object.Program (D:\github\andrewiggins\preact-transition-group\node_modules\nodent-compiler\output.js:182:18)
at Object.out (D:\github\andrewiggins\preact-transition-group\node_modules\nodent-compiler\output.js:125:11) |
|
I've opened MatAtBread/nodent-compiler#7 to address the build break. |
| const identity = i => i; | ||
|
|
||
| export class TransitionGroup extends Component { | ||
| static defaultProps = { |
There was a problem hiding this comment.
Buble doesn't support the property initializer syntax (bublejs/buble#123) nor the static keyword so I had to rewrite this code
| children: getChildMapping(this.props.children || []) | ||
| }; | ||
|
|
||
| this.performLeave = this.performLeave.bind(this); |
There was a problem hiding this comment.
Since Buble doesn't support property initializers, I had to bind the methods here :/
442f103 to
d223552
Compare
|
MatAtBread/nodent-compiler#7 is now closed and published as nodent-compiler v3.2.11. The build now passes! Note: you may need to delete your node-modules folder and re-install the packages in order to get the new nodent-compiler version. |
|
@developit, can you take a look when you get a chance? |
In preparation for some other work I'd like to do in this repo, I'm upgrading the dev environment to the latest and greatest from @developit. This repo now uses microbundle for bundling, karmatic for testing, and @developit's eslint rules for linting.
Bonus: Moving to microbundle shaved approximately 432 bytes 🎉