Skip to content
This repository has been archived by the owner on Jan 28, 2025. It is now read-only.

Delete old files from dist on build #1034

Merged
merged 1 commit into from
May 1, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/libs/lambda-at-edge/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
"@types/sharp": "^0.26.1",
"fetch-mock-jest": "^1.5.1",
"rollup": "^2.46.0",
"rollup-plugin-delete": "^2.0.0",
"rollup-plugin-node-externals": "^2.2.0",
"rollup-plugin-terser": "^7.0.2",
"rollup-plugin-typescript2": "^0.27.2",
Expand Down
6 changes: 6 additions & 0 deletions packages/libs/lambda-at-edge/rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { nodeResolve } from "@rollup/plugin-node-resolve";
import externals from "rollup-plugin-node-externals";
import json from "@rollup/plugin-json";
import { terser } from "rollup-plugin-terser";
import del from "rollup-plugin-delete";

const LOCAL_EXTERNALS = [
"./manifest.json",
Expand All @@ -21,6 +22,11 @@ const generateConfig = (input) => ({
format: "cjs"
},
plugins: [
del({
targets: `./dist/${input.filename}/${
input.minify ? "minified" : "standard"
}`
}),
json(),
commonjs(),
externals({
Expand Down
Loading