ちょっと前にBabelに末尾再帰最適化が入って話題になったけど、同じくTraceurにもv0.0.85で最適化が入ったので試してみた。 末尾再帰最適化って何? 厳密な話はそちらの筋に任せるとして、ざっくりしたストーリーはこんな感じ。 再帰って深くなるとstack overflowになっちゃう 再帰をシンプルなループ(スタックを使わないジャンプ)に変換できればstack overflowを避けられる 一般に末尾再帰であれば再帰をループに変換できる方法が知られている(これが末尾再帰最適化) 末尾再帰とは、関数の最後のステップだけで再帰呼び出しを行うこと 末尾再帰ではない再帰関数でも、CPS変換を使うことで末尾再帰関数に変換が可能 CPS変換とは、関数を結果の値を受け渡すスタイルから継続渡しスタイルに書き換えること つまり、普通の再帰関数 -> CPS変換で末尾再帰化 -> 末尾再帰最適化を適用
ES6 modules are set to become the future replacement for the AMD and CommonJS module formats. They are defined by the current ES6 Specification and will be implemented in JavaScript engines in the future in both the browser and the server. This article covers a variety of practical workflows for implementing ES6 modules. These approaches are very new, and there will still be edge cases, but these
Erik Arvidsson GitHub: @arv Twitter: @ErikArvidsson Language Improvements to JavaScript leads to: Better code Easier to maintain Happier Developers! Three topics on how to improve your code: ES6 features Part of all browsers soon Your own language extensions Make it part of your own tool chain Angular 2.0 language extensions Part of the Angular tool chain ECMAScript 6 What's new in ES6? How will i
さてさて二日目。 ひょんなことから円卓で座って会話したらイギリス英語とアメリカ英語の話になって、 「なんでナスってアメリカだとeggplantなんだよ、卵って紫じゃないだろw」 「イギリスのaubergine ってなんだよ、覚えられないよw」 みたいな会話に巻き込まれて、 「いやいや、そんな野菜よりも色のgreyとgrayの差のほうが深刻で、間違えやすいよ、CSSとかでどうしてるの?」 って言ったら 「ウェブの標準はアメリカ英語だから」 っていうマジレスを受けました。 二日目のセッションも色々と聞いてきてすげー面白かったので、まとめていきます。 node.js in production ab testing in netflix Netflix JavaScript Talks - Scaling A/B Testing on Netflix.com with Node.js from
Tweet Get ready for ECMAScript 6 JavaScript evolves, and the next 6th version will be awesome, we’ll have many great things like classes, maps, modules, … (probably much more, but I’m just starting to learn). There are several ways to begin writing ES6 source code (even now with shims, polyfills and transpilers), you can find a tools list here https://github.com/addyosmani/es6-tools. I chose the s
In my life, I have recognized immense benefit by consciously extending myself beyond what is comfortable.By choosing to encounter all that within me is unknown—fear, grief, and death; silence, ecstasy, and unity—I have uncovered a peace inside myself that seems to deepen my capacity to be with all the uncertainties of what it means to be human. Feeding this inquiry has allowed me to meet suffering
You can find (just about) anything on Medium — apparently even a page that doesn’t exist. Maybe these stories will take you somewhere new?
Author In ES6, Transpile To ES5 As A Build-step: A Workflow For Grunt April 29, 2013 Preface: This article assumes prior knowledge of Grunt, the JavaScript task runner and that you've heard of Traceur, the ES.next to ES5 transpiler by Google. Getting started guides are available for both projects. For information on the current state of ES6, read the current working draft spec. Today I used a Grun
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く