UNPKG

prutill

Version:

Environment-agnostic production-ready promise utility library for managing promise stacks and race conditions. Supports Node.js, Deno, and browsers.

85 lines (84 loc) 3.06 kB
{ "name": "prutill", "version": "1.2.0", "description": "Environment-agnostic production-ready promise utility library for managing promise stacks and race conditions. Supports Node.js, Deno, and browsers.", "main": "dist_commonjs/index.cjs", "module": "dist_es6/index.js", "types": "./index.ts", "type": "module", "exports": { ".": { "types": "./index.ts", "import": "./index.ts", "require": "./dist_commonjs/index.cjs" } }, "files": [ "dist_commonjs", "dist_es6", "src", "index.ts", "mod.js", "mod.ts" ], "scripts": { "build": "rm -rf dist_commonjs/* dist_es6/* && tsc --project tsconfig-commonjs.json && tsc --project tsconfig-es6.json && pnpm minify:all && pnpm rename-cjs && pnpm fix-maps", "rename-cjs": "find dist_commonjs -name '*.js' -exec sh -c 'mv \"$1\" \"${1%.js}.cjs\"' _ {} \\;", "fix-maps": "find dist_commonjs -name '*.map' -exec sh -c 'mv \"$1\" \"${1%.js.map}.cjs.map\"' _ {} \\;", "minify:all": "pnpm minify:commonjs && pnpm minify:es6", "minify:commonjs": "for file in $(find dist_commonjs -name '*.js'); do terser \"$file\" -c -m --source-map \"content='${file}.map',url='$(basename ${file%.*}).cjs.map'\" -o \"$file\"; done", "minify:es6": "for file in $(find dist_es6 -name '*.js'); do terser \"$file\" -c -m --source-map \"content='${file}.map',url='$(basename ${file}).map'\" -o \"$file\"; done", "test": "pnpm lint:all && jest && jest -c jest-node.config.json && pnpm test:deno", "test:coverage": "jest --coverage", "test:deno": "command -v deno >/dev/null 2>&1 && (deno test --config tsconfig-deno.json || exit 1) || (echo '\nℹ️ \u001b[33mDeno is not installed. Skipping Deno tests.\u001b[0m' && exit 0)", "lint": "eslint .", "tsc:check": "tsc --noEmit", "lint:md": "markdownlint \"**/*.md\" --fix", "format": "prettier --check \"**/*.{ts,js,json,md}\"", "lint:all": "pnpm tsc:check && pnpm lint && pnpm lint:md && pnpm publint && pnpm format", "publint": "npx publint", "lint:fix": "eslint . --fix", "format:fix": "prettier --write \"**/*.{ts,js,json,md}\"" }, "repository": { "type": "git", "url": "git+ssh://git@github.com:dominikj111/prutill.git" }, "keywords": [ "promise", "async", "utility", "typescript", "nodejs", "deno", "browser", "race-condition", "promise-stack", "cross-platform", "production-ready" ], "author": "dominikj111", "license": "Apache-2.0", "bugs": { "url": "https://github.com/dominikj111/prutill/issues" }, "homepage": "https://github.com/dominikj111/prutill#readme", "devDependencies": { "@eslint/js": "^9.20.0", "@types/jest": "^29.5.14", "@types/node": "^22.13.2", "@typescript-eslint/eslint-plugin": "^8.24.0", "@typescript-eslint/parser": "^8.24.0", "eslint": "^9.20.1", "eslint-config-prettier": "^10.0.1", "eslint-plugin-import": "^2.31.0", "eslint-plugin-prettier": "^5.2.3", "jest": "^29.7.0", "markdownlint-cli": "^0.44.0", "prettier": "^3.5.0", "terser": "^5.38.2", "ts-jest": "^29.2.5", "typescript": "^5.7.3" }, "packageManager": "pnpm@10.3.0" }