Skip to content

Commit

Permalink
website: fix color scheme flash on main page
Browse files Browse the repository at this point in the history
  • Loading branch information
terrablue committed Nov 29, 2023
1 parent 99ae313 commit 37b4dfb
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 9 deletions.
2 changes: 1 addition & 1 deletion packages/website/module.js
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ export default config => {
const { component, props } = page;
return view(component, props, { placeholders })(env, {}, request);
}
return next({ ...request, config });
return next({ ...request, config, placeholders });
},
};
};
8 changes: 4 additions & 4 deletions packages/website/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@
"private": true,
"dependencies": {
"@primate/build": "^0.2.0",
"@primate/frontend": "^0.9.0",
"@primate/frontend": "^0.9.2",
"@primate/liveview": "^0.9.0",
"esbuild": "^0.19.8",
"handlebars": "^4.7.8",
"highlight.js": "^11.9.0",
"marked": "^11.0.0",
"primate": "^0.27.2",
"primate": "^0.27.3",
"rcompat": "^0.5.0",
"svelte": "^4.2.7"
"svelte": "^4.2.7",
"handlebars": "^4.7.8"
},
"scripts": {
"local": "scripts/local.sh",
Expand Down
6 changes: 3 additions & 3 deletions packages/website/routes/blog.rss.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@ import { Path } from "rcompat/fs";
import { MediaType } from "rcompat/http";
import { view } from "primate";

const entries_path = [ "blog", "entries.json" ];
const entries_path = ["blog", "entries.json"];
const entries = new Path(import.meta.url).up(2).join(...entries_path);

export default {
async get() {
const props = { entries: await entries.json() };
const options = {
const options = {
partial: true,
headers: { "Content-Type": MediaType.APPLICATION_XML }
headers: { "Content-Type": MediaType.APPLICATION_XML },
};

return view("blog.rss.hbs", props, options);
Expand Down
5 changes: 4 additions & 1 deletion packages/website/routes/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@ import { view } from "primate";

export default {
get(request) {
return view("Homepage.svelte", { app: request.config });
const props = { app: request.config };
const options = { placeholders: request.placeholders };

return view("Homepage.svelte", props, options);
},
};

0 comments on commit 37b4dfb

Please sign in to comment.