Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README_js.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
```javascript --hide
import crypto from 'crypto';
import crypto from 'node:crypto';

runmd.onRequire = (path) => {
if (path == 'rng') return fun;
Expand Down
2 changes: 1 addition & 1 deletion src/md5.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { createHash } from 'crypto';
import { createHash } from 'node:crypto';

function md5(bytes: Uint8Array) {
if (Array.isArray(bytes)) {
Expand Down
2 changes: 1 addition & 1 deletion src/native.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
import { randomUUID } from 'crypto';
import { randomUUID } from 'node:crypto';

export default { randomUUID };
2 changes: 1 addition & 1 deletion src/rng.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { randomFillSync } from 'crypto';
import { randomFillSync } from 'node:crypto';

const rnds8Pool = new Uint8Array(256); // # of random values to pre-allocate
let poolPtr = rnds8Pool.length;
Expand Down
2 changes: 1 addition & 1 deletion src/sha1.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { createHash } from 'crypto';
import { createHash } from 'node:crypto';

function sha1(bytes: Uint8Array) {
if (Array.isArray(bytes)) {
Expand Down