some more spin.js porting