2025-09-11 23:48:23 +00:00
|
|
|
module.exports = {
|
|
|
|
|
output: "export",
|
|
|
|
|
distDir: process.env.NODE_ENV === "production" ? "./docs" : undefined,
|
|
|
|
|
basePath: "/t2-mapper",
|
|
|
|
|
assetPrefix: "/t2-mapper/",
|
|
|
|
|
trailingSlash: true,
|
2025-11-30 19:44:47 +00:00
|
|
|
async headers() {
|
|
|
|
|
return [
|
|
|
|
|
{
|
2025-12-05 05:25:38 +00:00
|
|
|
// TorqueScript files should be served as text. This won't affect what
|
|
|
|
|
// GitHub Pages does, but it'll at least improve the dev server. Otherwise,
|
|
|
|
|
// the responses can't be easily inspected in the Network tab.
|
2025-11-30 19:44:47 +00:00
|
|
|
source: "/:path*.cs",
|
|
|
|
|
headers: [
|
|
|
|
|
{
|
|
|
|
|
key: "Content-Type",
|
|
|
|
|
value: "text/plain; charset=utf-8",
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
];
|
|
|
|
|
},
|
2025-12-05 05:25:38 +00:00
|
|
|
async redirects() {
|
|
|
|
|
// For the dev server, redirect / to the `basePath` for convenience, so you
|
|
|
|
|
// can just open localhost:3000.
|
|
|
|
|
if (process.env.NODE_ENV !== "production") {
|
|
|
|
|
return [
|
|
|
|
|
{
|
|
|
|
|
source: "/",
|
|
|
|
|
destination: "/t2-mapper/",
|
|
|
|
|
basePath: false,
|
|
|
|
|
permanent: false,
|
|
|
|
|
},
|
|
|
|
|
];
|
|
|
|
|
}
|
|
|
|
|
return [];
|
|
|
|
|
},
|
2025-09-11 23:48:23 +00:00
|
|
|
};
|