@shad0wz7/nestjs-pdf 2.5.2 → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shad0wz7/nestjs-pdf",
3
- "version": "2.5.2",
3
+ "version": "3.0.0",
4
4
  "description": "A NestJS library for generating PDFs with Puppeteer and multiple engines.",
5
5
  "keywords": [
6
6
  "nestjs",
@@ -22,7 +22,7 @@
22
22
  },
23
23
  "license": "MIT",
24
24
  "author": "Emmanuel Boisset",
25
- "type": "commonjs",
25
+ "type": "module",
26
26
  "exports": {
27
27
  ".": {
28
28
  "types": "./dist/index.d.cts",
@@ -51,10 +51,10 @@
51
51
  "prepublishOnly": "pnpm lint && pnpm test && pnpm build",
52
52
  "sort": "sort-package-json",
53
53
  "sort:check": "sort-package-json --check",
54
- "test": "jest",
55
- "test:cov": "jest --coverage",
56
- "test:debug": "node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand",
57
- "test:watch": "jest --watch"
54
+ "test": "vitest run",
55
+ "test:cov": "vitest run --coverage",
56
+ "test:debug": "vitest --inspect-brk --no-file-parallelism",
57
+ "test:watch": "vitest"
58
58
  },
59
59
  "lint-staged": {
60
60
  "*.{ts,tsx,md,graphql,json,html,yaml,css}": [
@@ -62,107 +62,67 @@
62
62
  "pnpm format"
63
63
  ]
64
64
  },
65
- "jest": {
66
- "collectCoverageFrom": [
67
- "src/**/*.(t|j)s",
68
- "!src/index.ts"
69
- ],
70
- "coverageDirectory": "./coverage",
71
- "moduleFileExtensions": [
72
- "js",
73
- "json",
74
- "ts"
75
- ],
76
- "moduleNameMapper": {
77
- "@/(.*)$": "<rootDir>/src/$1",
78
- "^pdfjs-dist/legacy/build/pdf\\.mjs$": "<rootDir>/test/__mocks__/pdfjs-dist.ts",
79
- "^jwks-rsa$": "<rootDir>/test/__mocks__/jwks-rsa.ts"
80
- },
81
- "reporters": [
82
- "default",
83
- [
84
- "jest-junit",
85
- {
86
- "outputDirectory": "coverage"
87
- }
88
- ]
89
- ],
90
- "rootDir": ".",
91
- "roots": [
92
- "<rootDir>/src/"
93
- ],
94
- "setupFilesAfterEnv": [
95
- "<rootDir>/test/setup.ts"
96
- ],
97
- "testEnvironment": "node",
98
- "testRegex": ".*\\.spec\\.ts$",
99
- "transform": {
100
- "^.+\\.(t|j)s$": "ts-jest"
101
- },
102
- "transformIgnorePatterns": [
103
- "/node_modules/\\.pnpm/(?!(puppeteer[@+]|puppeteer-core[@+]|@puppeteer\\+))"
104
- ]
105
- },
106
65
  "dependencies": {
107
66
  "@puppeteer/browsers": "^3.2.1",
108
67
  "deepmerge-ts": "^8.0.2",
109
- "p-limit": "^7.3.1",
68
+ "p-limit": "^7.3.2",
110
69
  "pdf-lib": "^1.17.1",
111
- "pdfjs-dist": "^6.2.108",
70
+ "pdfjs-dist": "^6.3.289",
112
71
  "puppeteer": "^25.9.0"
113
72
  },
114
73
  "devDependencies": {
115
74
  "@eslint/js": "^10.0.1",
116
- "@nestjs/config": "^4.0.4",
117
- "@nestjs/schematics": "^11.1.0",
118
- "@nestjs/testing": "^11.2.3",
75
+ "@nestjs/cli": "^12.0.0",
76
+ "@nestjs/config": "^12.0.0",
77
+ "@nestjs/schematics": "^12.0.0",
78
+ "@nestjs/testing": "^12.0.1",
119
79
  "@swc/core": "^1.16.1",
120
80
  "@types/ejs": "^3.1.5",
121
- "@types/jest": "^30.0.0",
122
81
  "@types/mjml": "^5.0.0",
123
82
  "@types/mjml-core": "^5.1.0",
124
83
  "@types/mustache": "^4.2.6",
125
- "@types/node": "^26.3.0",
84
+ "@types/node": "^26.4.0",
126
85
  "@types/nunjucks": "^3.2.6",
127
86
  "@types/pug": "^2.0.10",
87
+ "@vitest/coverage-v8": "^4.1.11",
128
88
  "eslint": "^10.9.1",
129
89
  "eslint-config-prettier": "^10.1.8",
130
90
  "eslint-plugin-prettier": "^5.5.6",
131
91
  "eslint-plugin-simple-import-sort": "^14.0.0",
132
92
  "eslint-plugin-unused-imports": "^4.4.1",
133
- "globals": "^17.11.0",
93
+ "globals": "^17.12.0",
134
94
  "husky": "^9.1.7",
135
- "jest": "^30.4.2",
136
- "jest-junit": "^17.0.0",
137
- "knip": "^6.32.2",
138
- "lint-staged": "^17.3.0",
95
+ "knip": "^6.34.0",
96
+ "lint-staged": "^17.4.1",
139
97
  "prettier": "^3.9.6",
140
98
  "reflect-metadata": "^0.2.2",
141
99
  "sort-package-json": "^4.0.0",
142
- "ts-jest": "^29.4.12",
143
- "ts-node": "^10.9.2",
144
- "tsconfig-paths": "^4.2.0",
145
100
  "tsdown": "^0.22.14",
146
101
  "typescript": "^6.0.3",
147
- "typescript-eslint": "^8.68.0"
102
+ "typescript-eslint": "^8.69.0",
103
+ "unplugin-swc": "^1.5.11",
104
+ "vitest": "^4.1.11"
148
105
  },
149
106
  "peerDependencies": {
150
- "@nestjs/common": "^11.0.0",
151
- "@nestjs/core": "^11.0.0",
107
+ "@nestjs/common": "^12.0.0",
108
+ "@nestjs/core": "^12.0.0",
152
109
  "rxjs": "^7.8.0"
153
110
  },
154
111
  "optionalDependencies": {
155
- "@gboutte/nestjs-hbs": "^0.2.0",
156
112
  "@napi-rs/canvas": "^1.0.8",
157
113
  "ejs": "^6.0.1",
158
114
  "eta": "^4.6.0",
115
+ "handlebars": "^4.7.9",
159
116
  "mjml": "^5.4.0",
160
117
  "mjml-core": "^5.4.0",
161
118
  "mustache": "^4.2.0",
162
119
  "nunjucks": "^3.2.4",
163
120
  "pug": "^3.0.4"
164
121
  },
165
- "packageManager": "pnpm@11.22.0+sha512.1ff870c4c6133dfd88fb2afc46dd13d47f09c9794b438c6fdb47ca98caf3bc16381ee0be93a091b8e3824cf01f889f46d7d9e20910fb0be1ab0fb5baa80dd621",
122
+ "packageManager": "pnpm@11.25.0+sha512.5cde925b4f075f725eb71fbae18a42ffe784524789f19b61c731cb8721ec28aaee160e01a8d5af4fedb2a42cdbf300efe23db356b0d4a17b4d63e11f8ab7c956",
123
+ "engines": {
124
+ "node": "^20.19.0 || ^22.12.0 || >=24.0.0"
125
+ },
166
126
  "publishConfig": {
167
127
  "access": "public",
168
128
  "registry": "https://registry.npmjs.org/"