es**シリーズの仕様意訳第三回。前回はestraverseでした。今回はescope。 escope escopeは、ASTを喰ってスコープを解析するためのモジュール。 estraverseと同じように、ASTをescope.analyzeに喰わせるだけで動く。 デモを見ると挙動がよく分かる。サンプルコードがモナドなあたりに玄人臭を感じますねw 使い方は前回、前々回同様、超カンタン。 escopeとASTを吐かせるためのesprimaをnpmで取ってくる。 npm install esprima npm install escope あとはこんな感じで実行。 var esprima = require('esprima'); var escope = require('escope'); var ast = esprima.parse('console.log("Hello, world
What is power-assert? is an implementation of "Power Assert" concept in JavaScript. provides descriptive assertion messages through standard assert interface. No API is the best API. With power-assert, you don't need to learn many assertion library APIs (in most cases, all you need to remember is just an assert(any_expression) function) Stop memorizing tons of assertion APIs. Just create expressio
I spend a rather large fraction of my days inside Emacs, writing and editing JavaScript code. Of this time, a significant amount is spent doing things that follow patterns. Pattern which, with a little machine intelligence, could easily be automated. Years ago, before accidentally rolling into this JavaScript career, I mostly programmed Common Lisp. Emacs integration for Common Lisp is divine. It
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く