diff options
author | Hayleigh Thompson <me@hayleigh.dev> | 2023-08-22 23:33:45 +0100 |
---|---|---|
committer | Hayleigh Thompson <me@hayleigh.dev> | 2023-08-22 23:33:45 +0100 |
commit | 9bc9b6ae2664b63b02a8cb5a44660f7f225ad910 (patch) | |
tree | 086ac524707fb0798ff78b6b887d6fe8367be1f3 /lib/src/lustre.ffi.mjs | |
parent | 3f5114d3ad44347763e5b53e69b31c38e38f9a97 (diff) | |
download | lustre-9bc9b6ae2664b63b02a8cb5a44660f7f225ad910.tar.gz lustre-9bc9b6ae2664b63b02a8cb5a44660f7f225ad910.zip |
:sparkles: Make it possible to manually destroy a running lustre app.
Diffstat (limited to 'lib/src/lustre.ffi.mjs')
-rw-r--r-- | lib/src/lustre.ffi.mjs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/src/lustre.ffi.mjs b/lib/src/lustre.ffi.mjs index 51a6e26..29a60a9 100644 --- a/lib/src/lustre.ffi.mjs +++ b/lib/src/lustre.ffi.mjs @@ -122,7 +122,8 @@ export class App { } export const setup = (init, update, render) => new App(init, update, render); -export const start = (app, selector) => app.start(selector); +export const start = (app, selector, flags) => app.start(selector, flags); +export const destroy = (app) => app.destroy(); export const emit = (name, data) => // Normal `Effect`s constructed in Gleam from `effect.from` don't get told |