cosmjs/packages/amino/webpack.web.config.js

35 lines
730 B
JavaScript
Raw Permalink Normal View History

2021-04-14 19:05:09 +02:00
/* eslint-disable @typescript-eslint/naming-convention */
const glob = require("glob");
const path = require("path");
2021-05-20 13:37:43 +02:00
const webpack = require("webpack");
const target = "web";
const distdir = path.join(__dirname, "dist", "web");
module.exports = [
{
// bundle used for Karma tests
target: target,
entry: glob.sync("./build/**/*.spec.js"),
output: {
path: distdir,
filename: "tests.js",
},
2021-05-20 13:37:43 +02:00
plugins: [
new webpack.ProvidePlugin({
Buffer: ["buffer", "Buffer"],
}),
],
2021-04-14 17:35:53 +02:00
resolve: {
fallback: {
2021-05-19 17:46:21 +02:00
buffer: false,
crypto: false,
events: false,
path: false,
stream: false,
2021-05-19 17:46:21 +02:00
string_decoder: false,
2021-04-14 17:35:53 +02:00
},
},
},
];