Skip to content

Commit

Permalink
Prevent some 404s
Browse files Browse the repository at this point in the history
  • Loading branch information
jakearchibald committed Aug 6, 2019
1 parent 887e534 commit 1e0a3b4
Showing 1 changed file with 12 additions and 11 deletions.
23 changes: 12 additions & 11 deletions rollup.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -91,16 +91,19 @@ function buildConfig({ prerender, watch, lang } = {}) {
prerender
}),
glsl({ minify: !prerender }),
topLevelOutput &&
ejsAssetPlugin("./src/manifest.ejs", "manifest.json", {
data: {
nebulaSafeDark: nebulaHex
}
}),
ejsAssetPlugin("./src/manifest.ejs", "manifest.json", {
data: {
nebulaSafeDark: nebulaHex
}
}),
topLevelOutput &&
ejsAssetPlugin("./src/_redirects.ejs", "_redirects", {
data: { langs: langs.filter(l => l !== primaryLang) }
}),
topLevelOutput &&
addFilesPlugin({
"./src/_headers": "_headers"
}),
assetPlugin({
initialAssets: [
"./src/assets/space-mono-normal.woff2",
Expand All @@ -111,11 +114,9 @@ function buildConfig({ prerender, watch, lang } = {}) {
"./src/assets/icon.png"
]
}),
topLevelOutput &&
addFilesPlugin({
"./src/_headers": "_headers",
"./src/.well-known/assetlinks.json": ".well-known/assetlinks.json"
}),
addFilesPlugin({
"./src/.well-known/assetlinks.json": ".well-known/assetlinks.json"
}),
assetTransformPlugin(asset => {
if (asset.fileName.includes("manifest-")) {
// Remove name hashing
Expand Down

0 comments on commit 1e0a3b4

Please sign in to comment.