Skip to content

Commit

Permalink
WIP - Implement app.close() function.
Browse files Browse the repository at this point in the history
Closes elm#886.
  • Loading branch information
janwirth committed Feb 26, 2022
1 parent 65cea00 commit 0ba337d
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/Elm/Kernel/Platform.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,14 @@ function _Platform_initialize(flagDecoder, args, init, update, subscriptions, st

_Platform_enqueueEffects(managers, initPair.b, subscriptions(model));

return ports ? { ports: ports } : {};
const shutdown = function() {
managers = null
model = null
stepper = null
ports = null
}

return ports ? { ports: ports, shutdown: shutdown } : { shutdown: shutdown };
}


Expand Down

0 comments on commit 0ba337d

Please sign in to comment.