updated to support dot.js