move wrapper to js extension for backwards compatibility

This commit is contained in:
d98762625 2020-05-22 13:09:16 +01:00
parent 16db8b0b72
commit e9fcae8c49
2 changed files with 3 additions and 2 deletions

View file

@ -27,10 +27,10 @@
"type": "git",
"url": "https://github.com/gchq/CyberChef/"
},
"main": "./src/node/wrapper.cjs",
"main": "./src/node/wrapper.js",
"exports": {
"import": "./src/node/index.mjs",
"require": "./src/node/wrapper.cjs"
"require": "./src/node/wrapper.js"
},
"bugs": "https://github.com/gchq/CyberChef/issues",
"browserslist": [

View file

@ -7,6 +7,7 @@
* @license Apache-2.0
*/
console.log('CJS')
/* eslint no-global-assign: ["off"] */
require = require("esm")(module);
module.exports = require("./index.mjs");