Every single JavaScript engine supports standard timers *
These accept one or more extra argument by specs
for(var i = 0; i < 2; i++) {
setTimeout(function (i) {
console.log(i);
}, 0, i); // <== see this?
}
// modified from this: https://github.com/emiloberg/nativescript-emulator-reload | |
// all sources | |
var babelSrc = [ 'src/**/*.js', '!src/tns_modules', '!src/tns_modules/**', '!src/node_modules', '!src/node_modules/**' ]; | |
var jadeSrc = [ 'src/**/*.jade' ]; | |
var sassSrc = [ 'src/**/*.scss' ]; | |
var resources = [ 'src/{App_Resources,tns_modules,node_modules}/**', 'src/package.json']; | |
// Which emulator to run? |
Every single JavaScript engine supports standard timers *
These accept one or more extra argument by specs
for(var i = 0; i < 2; i++) {
setTimeout(function (i) {
console.log(i);
}, 0, i); // <== see this?
}
DISCLAIMER:
The whole content comes "as is".
All commentaries refer to author's impression.
Some inconsistency possible as well.
The few details (mainly useful links) were added while transcribing notes.
Add the following to your .bashrc (change path as necessary): | |
alias ruby='/cygdrive/c/Ruby193/bin/ruby' | |
alias gem='/cygdrive/c/Ruby193/bin/gem.bat' | |
alias irb='/cygdrive/c/Ruby193/bin/irb.bat' |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>Open 3 tabs</title> | |
<script src="http://codeorigin.jquery.com/jquery-1.10.2.min.js"></script> | |
</head> | |
<body> | |
<div id="hidden_div"></div> | |
<script> |
// geo-location shim | |
// currentely only serves lat/long | |
// depends on jQuery | |
// doublecheck the ClientLocation results because it may returning null results | |
;(function(geolocation){ | |
if (geolocation) return; |
Disclaimer 1: Первую которая "про то чего мы достигли" я таки пропустил.
Disclaimer 2: Многие доклады смотрелись и отчёты писались в состоянии алкогольного опьянения.
Сейчас посмотрел Ben Alpert - What Lies Ahead она про то какие идеи они имеют о дальнейшем развитии. И они делят на UX-идеи и DX-идеи. В UX у них:
// HOWTO: load LABjs itself dynamically! | |
// inline this code in your page to load LABjs itself dynamically, if you're so inclined. | |
(function (global, oDOC, handler) { | |
var head = oDOC.head || oDOC.getElementsByTagName("head"); | |
function LABjsLoaded() { | |
// do cool stuff with $LAB here | |
} |
/* | |
* Normalized hide address bar for iOS & Android | |
* (c) Scott Jehl, scottjehl.com | |
* MIT License | |
*/ | |
(function( win ){ | |
var doc = win.document; | |
// If there's a hash, or addEventListener is undefined, stop here | |
if( !location.hash && win.addEventListener ){ |
- Trailing commas are ok | |
- No reserved words for property names | |
- NaN, Infinity, undefined : are all constants | |
- parseInt() defaults to radix 10 | |
- /regexp/ produces new reg ex object every time | |
- JSON.parse(), JSON.stringify() | |
- Function.prototype.bind | |
- String.prototype.trim | |
- Array.prototype.every, filter, forEach, indexOf, lastIndexOf, map, reduce, reduceRight, some, | |
- Date.now() |