Skip to content

Commit

Permalink
Dependency Updates (0.4.4) (#10)
Browse files Browse the repository at this point in the history
* update wabac.js to 2.18.1 / wombat 3.7.4
* bump ipld/car and ipld/unixfs
* bump webpack
* more specific 
* add 'library' to webpack to ensure exports are not optimized out
  • Loading branch information
ikreymer authored Jun 3, 2024
1 parent 17eea44 commit 2a880a8
Show file tree
Hide file tree
Showing 4 changed files with 332 additions and 304 deletions.
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
"src/*"
],
"dependencies": {
"@ipld/car": "^5.1.1",
"@ipld/unixfs": "^2.1.1",
"@webrecorder/wabac": "2.17.3",
"@ipld/car": "^5.3.1",
"@ipld/unixfs": "^3.0.0",
"@webrecorder/wabac": "^2.18.1",
"auto-js-ipfs": "^2.3.0",
"client-zip": "^2.3.0",
"hash-wasm": "^4.9.0",
Expand Down
2 changes: 1 addition & 1 deletion src/ipfsutils.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { Downloader } from "./downloader.js";
import { create as createAutoIPFS } from "auto-js-ipfs";

import * as UnixFS from "@ipld/unixfs";
import { CarWriter } from "@ipld/car";
import { CarWriter } from "@ipld/car/writer";
import Queue from "p-queue";

// eslint-disable-next-line no-undef
Expand Down
17 changes: 17 additions & 0 deletions webpack.config.cjs
Original file line number Diff line number Diff line change
@@ -1,14 +1,31 @@
/*eslint-env node */

const webpack = require("webpack");
const TerserPlugin = require("terser-webpack-plugin");

const BANNER_TEXT = `'[name].js is part of the ArchiveWeb.page system (https://archiveweb.page) Copyright (C) 2020-${new Date().getFullYear()}, Webrecorder Software. Licensed under the Affero General Public License v3.'`;


module.exports = {
target: "webworker",
entry: {
"main": "./src/index.js",
},
output: {
filename: "sw.js",
library: {
type: "self"
}
},
optimization: {
minimize: true,
minimizer: [
new TerserPlugin({
extractComments: false,
}),
]
},

plugins: [
new webpack.NormalModuleReplacementPlugin(
/^node:*/,
Expand Down
Loading

0 comments on commit 2a880a8

Please sign in to comment.