Skip to content
Myr

chore: remove `crypto-js` from dev dependencies (#3447)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Yusuke Wada · committed by GitHub · parent 200c4f9 · Browse files · 6 files+11 added−19 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

6 files+11 added−19 removed

  • tests:+10 added−6 removed
  • other:+1 added−13 removed

6 files+11 added−19 removed

modified:runtime-tests/fastly/index.test.ts+2 added-2 removed
modified:src/middleware/basic-auth/index.test.ts+2 added-2 removed
1import { SHA256 } from 'crypto-js'1import { createHash } from 'crypto'2import { Hono } from '../../hono'3import { basicAuth } from '.'45describe('Basic Auth by Middleware', () => {
54 unmodified lines
60 '/auth-override-func/*',61 basicAuth({62 username: username,63 password: password,64 hashFunction: (data: string) => SHA256(data).toString(),64 hashFunction: (data: string) => createHash('sha256').update(data).digest('hex'),65 })66 )6768 app.use('/nested/*', async (c, next) => {
253 unmodified lines
modified:src/utils/buffer.test.ts+6 added-2 removed
1import { SHA256 as sha256CryptoJS } from 'crypto-js'1import { createHash } from 'crypto'2import { bufferToFormData, bufferToString, equal, timingSafeEqual } from './buffer'34describe('equal', () => {5 it('should return true for identical ArrayBuffers', () => {
35 unmodified lines
41 // @ts-ignore42 expect(await timingSafeEqual(undefined, undefined)).toBe(true)43 expect(await timingSafeEqual(true, true)).toBe(true)44 expect(await timingSafeEqual(false, false)).toBe(true)45 expect(await timingSafeEqual(true, true, (d: string) => sha256CryptoJS(d).toString()))45 expect(46 await timingSafeEqual(true, true, (d: boolean) =>47 createHash('sha256').update(d.toString()).digest('hex')48 )49 )50 })5152 it('negative', async () => {53 expect(await timingSafeEqual('a', 'b')).toBe(false)
67 unmodified lines
modified:bun.lockbbinary

A binary file, modified.

modified:package.json-2 removed
618 unmodified lines
619 ],620 "devDependencies": {621 "@hono/eslint-config": "^1.0.2",622 "@hono/node-server": "^1.8.2",623 "@types/crypto-js": "^4.1.1",623 "@types/glob": "^8.0.0",624 "@types/jsdom": "^21.1.4",625 "@types/node": "20.11.4",626 "@types/supertest": "^2.0.12",627 "@vitest/coverage-v8": "^2.0.5",628 "arg": "^5.0.2",630 "crypto-js": "^4.1.1",629 "esbuild": "^0.15.12",630 "eslint": "^9.10.0",631 "glob": "7.2.3",632 "jsdom": "^22.1.0",
16 unmodified lines
modified:yarn.lock+1 added-11 removed
1# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.2# yarn lockfile v13# bun ./bun.lockb --hash: DA11529C7F97C3FF-b3237be4d6b40612-FCFA012DAF0DCABC-52f32378b87f3da53# bun ./bun.lockb --hash: 229521234768470F-a4cd9955ab6a6ada-9D052F6AF60C5C4D-0bfb97a3d93af742456"@ampproject/remapping@^2.3.0":7 version "2.3.0"
1128 unmodified lines
1136 version "2.1.5"1137 resolved "https://registry.npmjs.org/@types/cookiejar/-/cookiejar-2.1.5.tgz"1138 integrity sha512-he+DHOWReW0nghN24E1WUqM0efK4kI9oTqDm6XmK8ZPe2djZ90BSNdGnIyCLzCPw7/pogPlGbzI2wHGGmi4O/Q==11391140"@types/crypto-js@^4.1.1":1141 version "4.2.2"1142 resolved "https://registry.npmjs.org/@types/crypto-js/-/crypto-js-4.2.2.tgz"1143 integrity sha512-sDOLlVbHhXpAUAL0YHDUUwDZf3iN4Bwi4W6a0W0b+QcAezUbRtH4FVb+9J4h+XFPW7l/gQ9F8qC7P+Ec4k8QVQ==11441140"@types/estree@1.0.5":1141 version "1.0.5"1142 resolved "https://registry.npmjs.org/@types/estree/-/estree-1.0.5.tgz"1143 integrity sha512-/kYRxGDLWzHOB7q+wtSUQlFrtcdUccpfy+X+9iMBpHK8QLLhx2wIPYuS5DYtR9Wa/YlZAbIovy7qVdB1Aq6Lyw==
917 unmodified lines
2061 path-key "^3.1.0"2062 shebang-command "^2.0.0"2063 which "^2.0.1"20642070crypto-js@^4.1.1:2071 version "4.2.0"2072 resolved "https://registry.npmjs.org/crypto-js/-/crypto-js-4.2.0.tgz"2073 integrity sha512-KALDyEYgpY+Rlob/iriUtjV6d5Eq+Y191A5g4UqLAi8CyGP9N1+FdVbkc1SxKc2r4YAYqG8JzO2KGL+AizD70Q==20742065crypto-random-string@^2.0.0:2066 version "2.0.0"2067 resolved "https://registry.npmjs.org/crypto-random-string/-/crypto-random-string-2.0.0.tgz"2068 integrity sha512-v1plID3y9r/lPhviJ1wrXpLeyUIGAZ2SHNYTEapm7/8A9nLPoyvVp3RK/EPFqn5kEznyWgYZNsRtYYIWbuG8KA==
4166 unmodified lines