ms/packages/ployfill/src/index.ts
MiaoWoo d1b6a4d4b2 feat: add core-js
Signed-off-by: MiaoWoo <admin@yumc.pw>
2020-02-09 22:06:45 +08:00

11 lines
549 B
TypeScript

/// <reference path="./global.ts" />
/// <reference types='@ms/nashorn' />
let ployfillStartTime = new Date().getTime();
console.info('Initialization Java Nashorn ployfill. Please wait...');
require('./es5-ext');
require('core-js');
global.setGlobal('Proxy', require('./proxy').Proxy)
global.setGlobal('XMLHttpRequest', require('./xml-http-request').XMLHttpRequest)
global.setGlobal('Blob', require('blob-polyfill').Blob)
console.info('Java Nashorn ployfill loading completed... Cost (' + (new Date().getTime() - ployfillStartTime) / 1000 + 's)!');