feat(server): add safety checks during dev (#1489)
Co-authored-by: Reed von Redwitz <reed+github@vonredwitz.com>
This commit is contained in:
co-authored by
Reed von Redwitz
parent
430be774e2
commit
a7fe9d04f1
@@ -0,0 +1,15 @@
|
||||
import { Plugin } from "$fresh/server.ts";
|
||||
|
||||
export default function notHavingModules(): Plugin {
|
||||
return {
|
||||
name: "not_having_modules",
|
||||
entrypoints: { "main": "() => {}" },
|
||||
render(ctx) {
|
||||
ctx.render();
|
||||
|
||||
return {
|
||||
scripts: [{ entrypoint: "main", state: [] }],
|
||||
};
|
||||
},
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user