moving performance.now into lib