feat(server): add safety checks during dev (#1489)

Co-authored-by: Reed von Redwitz <reed+github@vonredwitz.com>
This commit is contained in:
Michael Herzner
2023-07-31 11:48:26 +02:00
committed by GitHub
co-authored by Reed von Redwitz
parent 430be774e2
commit a7fe9d04f1
20 changed files with 398 additions and 18 deletions
@@ -5,7 +5,6 @@ let CSS_TO_INJECT = "h1 { text-decoration: underline; }";
export default {
name: "css-inject-async",
async renderAsync(ctx) {
await new Promise((res) => setTimeout(res, 50));
const res = await ctx.renderAsync();
if (res.requiresHydration) {
CSS_TO_INJECT += " h1 { font-style: italic; }";