Skip to content

Commit

Permalink
Merge pull request MasterKale#518 from balazsorban44/master
Browse files Browse the repository at this point in the history
fix(server): ignore `import("node:crypto")` by webpack
  • Loading branch information
MasterKale authored Feb 9, 2024
2 parents ba7048c + 66c254c commit 3037a46
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packages/server/src/helpers/iso/isoCrypto/getWebCrypto.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,11 @@ export const _getWebCryptoInternals = {
stubThisImportNodeCrypto: async () => {
try {
// dnt-shim-ignore
const _nodeCrypto = await import('node:crypto');
/**
* The `webpackIgnore` here is to help support Next.js' Edge runtime.
* See https://github.com/MasterKale/SimpleWebAuthn/issues/517 for more info.
*/
const _nodeCrypto = await import(/* webpackIgnore: true */ 'node:crypto');
return _nodeCrypto;
} catch (_err) {
/**
Expand Down

0 comments on commit 3037a46

Please sign in to comment.