rwsdk
Version:
Build fast, server-driven webapps on Cloudflare with SSR, RSC, and realtime
13 lines (12 loc) • 378 B
JavaScript
import { $sh } from "../lib/$.mjs";
export const moveStaticAssetsPlugin = ({ rootDir, }) => ({
name: "rwsdk:move-static-assets",
apply: "build",
async closeBundle() {
if (this.environment.name === "worker") {
await $sh({
cwd: rootDir,
}) `mv dist/worker/assets/*.css dist/client/assets/ || true`;
}
},
});