Files
my-protfolio/scripts/prepare-standalone.mjs
Amirhossein Khalili 24cd86ede7
Some checks failed
Test and deploy / Verify production build (push) Has been cancelled
Test and deploy / Deploy production (push) Has been cancelled
feat: add route-backed project case studies
2026-09-09 22:00:57 +03:30

13 lines
411 B
JavaScript

import { cp } from 'node:fs/promises';
import path from 'node:path';
const projectRoot = path.resolve('.');
const standaloneRoot = path.join(projectRoot, '.next', 'standalone');
await cp(path.join(projectRoot, 'public'), path.join(standaloneRoot, 'public'), { recursive: true });
await cp(
path.join(projectRoot, '.next', 'static'),
path.join(standaloneRoot, '.next', 'static'),
{ recursive: true },
);