mirror of
https://github.com/simstudioai/sim.git
synced 2026-04-28 03:00:29 -04:00
* fix(core): consolidate ID generation to prevent HTTP self-hosted crashes crypto.randomUUID() requires a secure context (HTTPS) in browsers, causing white-screen crashes on self-hosted HTTP deployments. This replaces all direct usage of crypto.randomUUID(), nanoid, and the uuid package with a central utility that falls back to crypto.getRandomValues() which works in all contexts. - Add generateId(), generateShortId(), isValidUuid() in @/lib/core/utils/uuid - Replace crypto.randomUUID() imports across ~220 server + client files - Replace nanoid imports with generateShortId() - Replace uuid package validate with isValidUuid() - Remove nanoid dependency from apps/sim and packages/testing - Remove browser polyfill script from layout.tsx - Update test mocks to target @/lib/core/utils/uuid - Update CLAUDE.md, AGENTS.md, cursor rules, claude rules Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * update bunlock * fix(core): remove UUID_REGEX shim, use isValidUuid directly * fix(core): remove deprecated uuid mock helpers that use vi.doMock --------- Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
61 lines
1.4 KiB
JSON
61 lines
1.4 KiB
JSON
{
|
|
"name": "@sim/testing",
|
|
"version": "0.1.0",
|
|
"private": true,
|
|
"sideEffects": [
|
|
"./src/setup/*"
|
|
],
|
|
"type": "module",
|
|
"license": "Apache-2.0",
|
|
"engines": {
|
|
"bun": ">=1.2.13",
|
|
"node": ">=20.0.0"
|
|
},
|
|
"exports": {
|
|
".": {
|
|
"types": "./src/index.ts",
|
|
"default": "./src/index.ts"
|
|
},
|
|
"./factories": {
|
|
"types": "./src/factories/index.ts",
|
|
"default": "./src/factories/index.ts"
|
|
},
|
|
"./builders": {
|
|
"types": "./src/builders/index.ts",
|
|
"default": "./src/builders/index.ts"
|
|
},
|
|
"./mocks": {
|
|
"types": "./src/mocks/index.ts",
|
|
"default": "./src/mocks/index.ts"
|
|
},
|
|
"./mocks/executor": {
|
|
"types": "./src/mocks/executor.mock.ts",
|
|
"default": "./src/mocks/executor.mock.ts"
|
|
},
|
|
"./assertions": {
|
|
"types": "./src/assertions/index.ts",
|
|
"default": "./src/assertions/index.ts"
|
|
},
|
|
"./setup": {
|
|
"types": "./src/setup/vitest.setup.ts",
|
|
"default": "./src/setup/vitest.setup.ts"
|
|
}
|
|
},
|
|
"scripts": {
|
|
"type-check": "tsc --noEmit",
|
|
"lint": "biome check --write --unsafe .",
|
|
"lint:check": "biome check .",
|
|
"format": "biome format --write .",
|
|
"format:check": "biome format ."
|
|
},
|
|
"peerDependencies": {
|
|
"vitest": "^3.0.0"
|
|
},
|
|
"devDependencies": {
|
|
"@sim/tsconfig": "workspace:*",
|
|
"typescript": "^5.7.3",
|
|
"vitest": "^3.0.8"
|
|
},
|
|
"dependencies": {}
|
|
}
|