File tree Expand file tree Collapse file tree 4 files changed +4546
-4502
lines changed Expand file tree Collapse file tree 4 files changed +4546
-4502
lines changed Original file line number Diff line number Diff line change 16
16
strategy :
17
17
matrix :
18
18
os : [ubuntu-latest]
19
- node : [18 ]
19
+ node : [20 ]
20
20
21
21
steps :
22
22
- uses : actions/setup-node@v3
Original file line number Diff line number Diff line change 4
4
"license" : " MIT" ,
5
5
"type" : " module" ,
6
6
"engines" : {
7
- "node" : " >=18 .0.0"
7
+ "node" : " >=20 .0.0"
8
8
},
9
9
"homepage" : " https://nuxt-security.vercel.app" ,
10
10
"description" : " 🛡️ Security Module for Nuxt based on HTTP Headers and Middleware" ,
68
68
"@nuxt/module-builder" : " ^0.8.3" ,
69
69
"@nuxt/schema" : " ^3.11.2" ,
70
70
"@nuxt/test-utils" : " ^3.12.0" ,
71
- "@types/node" : " ^18.18.1 " ,
71
+ "@types/node" : " ^20.14.8 " ,
72
72
"changelogen" : " ^0.5.7" ,
73
73
"eslint" : " ^8.50.0" ,
74
74
"nuxt" : " ^3.11.2" ,
Original file line number Diff line number Diff line change 1
- // These two lines are required only to maintain compatibility with Node 18
2
- // - In Node 19 and above, crypto is available in the global scope
3
- // - In Workers environments, crypto is available in the global scope
4
- import { webcrypto } from 'node:crypto'
5
- globalThis . crypto ??= webcrypto as Crypto
6
-
7
1
export async function generateHash ( content : Buffer | string , hashAlgorithm : 'SHA-256' | 'SHA-384' | 'SHA-512' ) {
8
2
let buffer : Uint8Array
9
3
if ( typeof content === 'string' ) {
You can’t perform that action at this time.
0 commit comments