gulpのAPIマニュアルにも書かれていますが、gulpでは、gulp.destを書いたからと言って、そこで終わりにする必要はありません。 注: 下記、CoffeeScriptで書いてますが、gulpの標準はJavaScriptです。適宜読み替えてください。 例: 複数ディレクトリに出力する 例えば、こんな風に書けば、3つのディレクトリにテキストファイルをコピーできます。 gulp = require 'gulp' gulp.task 'multi-dist', -> gulp.src ['./src/*.txt'] .pipe gulp.dest './dist1/' # 1つ目のdest .pipe gulp.dest './dist2/' # 2つ目のdest .pipe gulp.dest './dist3/' # 3つ目のdest
or #v86 on irc.libera.chat v86 emulates an x86-compatible CPU and hardware. Machine code is translated to WebAssembly modules at runtime in order to achieve decent performance. Here's a list of emulated hardware: An x86-compatible CPU. The instruction set is around Pentium 4 level, including full SSE3 support. Some features are missing, in particular: Task gates, far calls in protected mode Some 1
A small example exploring how to integrate D3.js data visualizations into a React app. I've been working with D3.js and React lately, and in this post I wanted to share a few ways I found in building components and the interface between them. I think they help make both libraries work together quite nicely. We'll be building a small example to illustrate this, and you can find the full code on Git
さてさて、io.js ver.1.0.0, 1.0.1 が無事アメリカ時間の1/13日に予告通りリリースされました。 リリースから数日経過して、現在はv1.0.3が出ています。 ある程度v1.0が安定してきた今、実際にNode.jsとどう違うのかを解説したいと思います。 Node.jsと機能的に違う所はどこか 前回の記事のio.jsについて知っていること - from scratchでも触れたんですが、一番大きな違いはv8が新しくなり、ES6の機能が増えました。 詳しくは公式のES6に関するページを読んでもらうとして、かいつまんで書いていきます。 ES6の機能に"shipping", "staged", "in_progress"の3段階のラベルがつくようになりました。 これはES6の機能の安定度合いを示していて、 "shipping" > "staged" > "in_progress"
If you're interested in getting the latest and greatest in Marionette, help by making a book on v3 a reality here. I might be writing a new book covering v3. I don't know whether there will be enough interest to warrant it, or when it will be ready, so you'll probably still want to pick this one up: current readers will get a major discount on the new book when it ships. The book is up to date for
checkboxやradioのチェック状態を調べる際にはattrではなくpropを使うのが良い。 attrでも取れないこともないですが、propで取得する方が処理が早いです。 特にIEの場合、inputに対するdisabledの処理がものすごく重く、attrでdisabledやcheckedの処理を沢山していると、無駄に最悪な感じで負荷がかかります。 attrとpropの取得の違い## またこの2つは、同じ値を取得してるようで異なる値を取得するので注意。 例えば の場合、 チェック時 prop true attr checked 非チェック時 prop false attr undefined という全然違う値が返ってきます。 なぜ解釈が違うのか## attrは純粋に 属性における値 を取得するので、この場合は、 checkされてない ↓ checkedという『属性』がない! ↓ unde
それぞれ、このシリーズの後続の回で詳しく触れていきますが、Application、AppRouter、ControllerはViewやModelの間を取り持つ機能を担っています。ItemView、CollecttonView、CompositeView、Region、Layoutはそれぞれ異なった役割で、View周りのコーディングに役立つ機能を持っています。 Marionette.jsにできること Marionette.jsから得られる恩恵は大小さまざまで、細かいものを挙げていくときりがないほどですが、大きなものを挙げるとすれば、次のような点があります。 モジュール化のサポート 開発者が書かなければならないコード量の減少 機能の部分的な利用 モジュール化のサポート Marionette.jsの機能の中で大きなものとして、モジュール化のサポートがあります。モジュール化というのは、ある機能を表
var app, base, concat, directory, gulp, gutil, hostname, path, refresh, sass, uglify, del, connect, autoprefixer, babel; var autoPrefixBrowserList = ['last 2 version', 'safari 5', 'ie 8', 'ie 9', 'opera 12.1', 'ios 6', 'android 4']; gulp = require('gulp'); gutil = require('gulp-util'); concat = require('gulp-concat'); uglify = require('gulp-uglify'); sass = require('gulp-sass'); connect = require(
昨日のエントリの続き。こっちのほうが有益な情報になってると思うんだけど多分昨日ほどはのびない。 さて、昨日のエントリーでは「Backbone.jsのViewはControllerってことなのか〜それは俺が間違えてたわ〜、えっじゃあ Marionette.js 使う場合はどうなの」という感じになったのだけれど、そのあといろいろ考えて以下のような感じに落ち着いた。 Marionette.jsを使っていたとしても結局考え方はBackbone.jsのときとかわらない。 つまり、Marionette.js の View も C である。ViewControllerと言うべきかもしれないので以下ではViewControllerと書く。 ViewControllerの責務は、以下の通りである。 Model(あるいはCollection)をひとつ保持し、View(HTML片のことである)をひとつ保持する
事の発端。 jQueryの使わない機能があまりに多いのでカスタムビルドすることにした Sizzleも外せることを知る(容量がgzipで20KB分くらい減る) 外すと何が変わるか気になる <- いまここ ってなモチベーションで調べた一連の内容です。 jQueryとSizzleの関係 あらためて一応。 「jQueryといえば」な以下のようなコード。 var $hoge = $('#hoge'); // こういうのとか var $fuga = $('.fuga'); // こういうのとか $hoge.find('.foo'); // こういうのとか $hoge.text(); // 実はこういうのも そう、いわゆるこのセレクタの実態がSizzleなのです。 正確にはもう少し他のメソッドにも関係があります。 jquery/sizzle で、そのSizzleがjQueryの中でどういう動きをしてるか
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く