diff --git a/package.json b/package.json index 397f8f77..c16dfd39 100644 --- a/package.json +++ b/package.json @@ -42,7 +42,7 @@ "schema": "ts-json-schema-generator -f tsconfig.json -p 'src/{modules/**/*.ts,lib/options.ts}' -t '*' | node bin/schema-tweak.js > schema.json", "build": "yarn run build:esm && yarn run build:cjs && yarn run build:post", "build:esm": "tsc --module es2020 --outDir dist/esm", - "build:cjs": "tsc --module commonjs --outDir dist/cjs && sed -i 's/\"type\": \"module\",/\"type:\": \"commonjs\",/' dist/cjs/package.json", + "build:cjs": "tsc --module commonjs --target es2015 --outDir dist/cjs && sed -i 's/\"type\": \"module\",/\"type:\": \"commonjs\",/' dist/cjs/package.json", "build:post": "bin/json-transform.sh", "generateSchema": "yarn schema", "prepublishOnly": "yarn build && yarn generateSchema && yarn build:post",