]> git.ardis.lu - envpass/commitdiff
Use more idiomatic types
authorArdis Lu <ardisglu@gmail.com>
Fri, 17 Jul 2026 06:45:38 +0000 (23:45 -0700)
committerArdis Lu <ardisglu@gmail.com>
Fri, 17 Jul 2026 06:45:38 +0000 (23:45 -0700)
src/utils.js
test/getPrf.test.js

index d9ee0ea93043c6722e310dfc7d27698763e32c50..a757e1b1191b61f8fbea23dbd185784fda08407a 100644 (file)
@@ -1,5 +1,5 @@
 /**
- * @typedef {object} Logger Logger interface for diagnostic output. Compatible with `console` and
+ * @typedef {Object} Logger Logger interface for diagnostic output. Compatible with `console` and
  * most logging libraries.
  * @property {(...args: unknown[]) => void} [debug] Logs verbose diagnostic information.
  * @property {(...args: unknown[]) => void} [info] Logs informational messages.
@@ -8,7 +8,7 @@
  */
 
 /**
- * @typedef {{[key:string]:string|undefined}} Env A simple null prototype object dictionary to map environment
+ * @typedef {Record<string,string|undefined>} Env A simple null prototype object dictionary to map environment
  * variable names to values.
  */
 
index ba1ed498ab1931e42332a0ec9df7ccfa1ce9821b..12911ba8e4e86b6548f2cf4a564e2dfe5c956d5e 100644 (file)
@@ -89,7 +89,7 @@ suite('getPrf.js (server)', () => {
     const prf = Uint8Array.fromHex('deadbeef000000000000000000000000000000000000000000000000cafebabe');
     const options = {
       method: 'POST',
-      headers: /** @type {{[key:string]:string}} */({
+      headers: /** @type {Record<string,string>} */({
         'Content-Type': 'application/octet-stream',
         'Origin': origin,
         'Sec-Fetch-Site': 'same-origin',
This page took 0.042987 seconds and 4 git commands to generate.