Allow importing libHash to succeed in browser

Alsthough this does not make libHash work in the browser it allows other
modules to require libHash while still being exported to the browser.
This commit is contained in:
Hornwitser committed 2022-08-24 15:42:26 +02:00
1 parent a40fefc8d7
commit 921ebad8fb
2 files changed
+3 -1

No files matched your search

+1 -1
View File
@@ -4,7 +4,7 @@
*/
"use strict";
const crypto = require("crypto");
const fs = require("fs");
const fs = require("fs-extra");
/**
+2
View File
@@ -95,6 +95,8 @@ module.exports = (env = {}) => ({
resolve: {
extensions: [".js", ".json", ".jsx"],
fallback: {
"crypto": false,
// Required for winston
"util": require.resolve("util/"),
"os": require.resolve("os-browserify/browser"),