elm-pages-v3-beta/examples/hello/index.ts

17 lines
371 B
TypeScript
Raw Normal View History

2022-03-10 02:06:49 +03:00
type ElmPagesInit = {
load: (elmLoaded: Promise<unknown>) => Promise<void>;
flags: unknown;
};
2022-03-04 23:32:52 +03:00
2022-03-10 02:06:49 +03:00
const config: ElmPagesInit = {
2022-03-04 23:32:52 +03:00
load: async function (elmLoaded) {
const app = await elmLoaded;
console.log("App loaded", app);
},
flags: function () {
return "You can decode this in Shared.elm using Json.Decode.string!";
},
};
2022-03-10 02:06:49 +03:00
export default config;