Show HN: Kneden – Transpile ES7 Async/await to ES6 Promise Chains (Babel Plugin)
github.com
github.com
If they are not though, Kneden will generate code that's probably more readable and smaller (no polyfill except for a Promise implementation).
I like async/await a lot, but I'm concerned at how much all of this JS machinery costs in terms of perf, especially compared to writing callback chains.
That said, it might be a good idea to hand-optimize that single hot loop, typing the Promise chain out yourself, or even using callbacks directly. It's impossible to beat that using an automated solution like this.
Pragmatic and it works, but the code isn't pretty. Which is why Kneden was made.
But note that it's shipped as a babel plugin, so you shouldn't even need to care.
What this really is is "use the currently-most-popular JS transformation toolchain to transform cool-JS to works-in-browser-JS". Whether part X is in the ES6 standard and part Y might end up in ES7 is really mostly besides the point.
Anyway, I agree, the sooner Kneden becomes obsolete, the better!
This isn't like TypeScript or CoffeeScript where you're always transpiling.
Maybe something changed since the last time I tried, or perhaps i mis-configured something? How are error messages and debugging with this plugin?