-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Don't introduce browserify in SDK in non-node target
- Loading branch information
1 parent
54b672b
commit 79481f4
Showing
4 changed files
with
230 additions
and
217 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
|
||
let _subtle: SubtleCrypto | undefined | ||
|
||
export function _set_subtle_crypto(s: SubtleCrypto) { | ||
_subtle = s | ||
} | ||
|
||
export function subtle(): SubtleCrypto { | ||
if (_subtle != undefined) { | ||
return _subtle | ||
} else { | ||
return window.crypto.subtle | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.