|
2 | 2 | "name": "@byu-oit/logger",
|
3 | 3 | "version": "0.4.2",
|
4 | 4 | "description": "Default configuration for pino logger",
|
| 5 | + "engines": { |
| 6 | + "node": ">=18" |
| 7 | + }, |
5 | 8 | "contributors": [
|
6 | 9 | {
|
7 | 10 | "name": "Scott Hutching",
|
|
12 | 15 |
|
13 | 16 | }
|
14 | 17 | ],
|
15 |
| - "main": "dist/logger.js", |
16 |
| - "types": "dist/logger.d.ts", |
| 18 | + "type": "module", |
| 19 | + "main": "./dist/cjs/index.js", |
| 20 | + "types": "./dist/cjs/index.d.ts", |
| 21 | + "exports": { |
| 22 | + "./package.json": "./package.json", |
| 23 | + ".": { |
| 24 | + "import": { |
| 25 | + "types": "./dist/esm/index.d.ts", |
| 26 | + "default": "./dist/esm/index.js" |
| 27 | + }, |
| 28 | + "require": { |
| 29 | + "types": "./dist/cjs/index.d.ts", |
| 30 | + "default": "./dist/cjs/index.js" |
| 31 | + } |
| 32 | + } |
| 33 | + }, |
17 | 34 | "files": [
|
18 | 35 | "dist"
|
19 | 36 | ],
|
20 | 37 | "scripts": {
|
21 |
| - "build": "npx rimraf dist && tsc", |
22 |
| - "coverage": "npm run test -- --coverage || exit 0", |
| 38 | + "build": "rimraf dist && concurrently \"npm:build:*\" -c cyanBright", |
| 39 | + "build:cjs": "tsc -p tsconfig.cjs.json && echo-cli \"{\\\"type\\\": \\\"commonjs\\\"}\" > dist/cjs/package.json", |
| 40 | + "build:esm": "tsc -p tsconfig.json && echo-cli \"{\\\"type\\\": \\\"module\\\"}\" > dist/esm/package.json", |
| 41 | + "clean": "rimraf dist", |
| 42 | + "coverage": "c8 ava", |
23 | 43 | "lint": "npx ts-standard | snazzy",
|
24 | 44 | "lint:fix": "npx ts-standard --fix | snazzy",
|
25 |
| - "test": "jest", |
| 45 | + "test": "ava", |
26 | 46 | "prepublishOnly": "npm run build"
|
27 | 47 | },
|
28 | 48 | "author": "Brigham Young University - Office of Information Technology",
|
29 | 49 | "license": "Apache-2.0",
|
| 50 | + "repository": { |
| 51 | + "type": "git", |
| 52 | + "url": "git+https://github.com/byu-oit/logger.git" |
| 53 | + }, |
| 54 | + "bugs": { |
| 55 | + "url": "https://github.com/byu-oit/logger/issues" |
| 56 | + }, |
30 | 57 | "dependencies": {
|
31 | 58 | "deepmerge": "^4.2.2",
|
32 | 59 | "pino": "^8.11.0",
|
33 | 60 | "pino-http": "^6.6.0"
|
34 | 61 | },
|
35 | 62 | "devDependencies": {
|
36 |
| - "@tsconfig/node12": "^1.0.11", |
| 63 | + "@tsconfig/node18": "^18.2.4", |
37 | 64 | "@types/jest": "^29.5.0",
|
38 |
| - "@types/node": "^16.9.1", |
39 |
| - "jest": "^29.5.0", |
| 65 | + "@types/node": "^18.19.42", |
| 66 | + "@types/sinon": "^17.0.3", |
| 67 | + "ava": "^6.1.3", |
| 68 | + "c8": "^10.1.2", |
| 69 | + "concurrently": "^8.2.2", |
| 70 | + "echo-cli": "^2.0.0", |
40 | 71 | "lint-staged": "^12.0.2",
|
41 | 72 | "pino-pretty": "^10.0.0",
|
| 73 | + "rimraf": "^6.0.1", |
| 74 | + "sinon": "^18.0.0", |
42 | 75 | "snazzy": "^9.0.0",
|
43 |
| - "ts-jest": "^29.1.0", |
| 76 | + "tsimp": "^2.0.11", |
44 | 77 | "typescript": "^5.0.3"
|
45 | 78 | },
|
46 | 79 | "optionalDependencies": {
|
47 | 80 | "pino-pretty": ">=7"
|
48 | 81 | },
|
49 |
| - "engines": { |
50 |
| - "node": ">=12" |
51 |
| - }, |
52 |
| - "jest": { |
53 |
| - "transform": { |
54 |
| - "^.+\\.(ts|tsx)$": "ts-jest" |
55 |
| - } |
56 |
| - }, |
57 | 82 | "lint-staged": {
|
58 | 83 | "*.ts": "npm run lint:fix"
|
59 | 84 | },
|
60 |
| - "repository": { |
61 |
| - "type": "git", |
62 |
| - "url": "git+https://github.com/byu-oit/logger.git" |
63 |
| - }, |
64 |
| - "bugs": { |
65 |
| - "url": "https://github.com/byu-oit/logger/issues" |
| 85 | + "ava": { |
| 86 | + "extensions": { |
| 87 | + "ts": "module" |
| 88 | + }, |
| 89 | + "nodeArguments": [ |
| 90 | + "--import=tsimp" |
| 91 | + ] |
66 | 92 | }
|
67 | 93 | }
|
0 commit comments