UNPKG

ts-add-js-extension

Version:

Add .js extension to each relative ESM import and export statement in JavaScript file

68 lines (67 loc) 1.99 kB
{ "name": "ts-add-js-extension", "description": "Add .js extension to each relative ESM import and export statement in JavaScript file", "version": "1.6.5", "license": "MIT", "main": "./build/cjs/index.js", "module": "./build/mjs/index.js", "types": "./build/cjs/index.d.ts", "react-native": "./build/mjs/index.js", "exports": { "./package.json": "./package.json", ".": { "require": "./build/cjs/index.js", "import": "./build/mjs/index.js", "default": "./build/mjs/index.js" } }, "bin": { "ts-add-js-extension": "./build/cjs/bin.js" }, "files": [ "build" ], "scripts": { "lint": "eslint . --color", "format": "prettier-config-generate && prettier .", "format-write": "pnpm format --write", "format-check": "pnpm format --check", "build-cjs": "tsc -p tsconfig.cjs.json && shx chmod +x build/cjs/bin.js", "build-mjs": "tsc -p tsconfig.mjs.json && node build/cjs/bin.js --dir build/mjs", "prebuild": "vite-node script/package.ts", "build": "pnpm prebuild && shx rm -rf build && pnpm build-cjs && pnpm build-mjs && node-package-helper", "test-setup": "cd test/process && shx rm -rf actual-result && shx cp -r source actual-result && pnpm prebuild", "pretest": "pnpm test-setup && pnpm prebuild", "test": "pnpm pretest && vitest" }, "bugs": "https://github.com/GervinFung/ts-add-js-extension/issues", "repository": { "type": "git", "url": "https://github.com/GervinFung/ts-add-js-extension" }, "dependencies": { "typescript": "^5.6.3" }, "devDependencies": { "@poolofdeath20/eslint-config": "^0.4.1", "@poolofdeath20/prettier-config-generator": "^0.0.1", "@poolofdeath20/tsconfig": "^0.1.1", "@types/node": "^22.8.7", "eslint": "^9.14.0", "node-package-helper": "github:GervinFung/node-package-helper", "prettier": "^3.3.3", "shx": "^0.3.4", "vite-node": "^2.1.4", "vitest": "^2.1.4" }, "keywords": [ "esm", "tsc", "mjs", "js", "typescript", "javascript", "js extension", "esnext" ] }