/
Soraa
/
claude-code
Обзор
Документация
Войти
/
Soraa
/
claude-code
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
utils/crypto.ts
13 строк
763 B
kuberwastaken
new initial commit (history rewritten)
01 апр 2026, 14:57
01 апр 2026, 14:57
c1996f2
Код
Авторство
О чём код?
// Indirection point for the package.json "browser" field. When bun builds // browser-sdk.js with --target browser, this file is swapped for // crypto.browser.ts — avoiding a ~500KB crypto-browserify polyfill that Bun // would otherwise inline for `import ... from 'crypto'`. Node/bun builds use // this file unchanged. // // NOTE: `export { randomUUID } from 'crypto'` (re-export syntax) breaks under // bun-internal's bytecode compilation — the generated bytecode shows the // import but the binding doesn't link (`ReferenceError: randomUUID is not // defined`). The explicit import-then-export below produces a correct live // binding. See integration-tests-ant-native failure on PR #20957/#21178. import { randomUUID } from 'crypto' export { randomUUID }