snapshot of platform.js