Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.
Sign upHow to teardown a module instantiated with `Elm.embed` #432
Comments
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
Show comment
Hide comment
danneu
Nov 28, 2015
Looks like fullscreen and embed return an object with three methods, one of them being .dispose().
Source: elm-core/Native/Runtime.js#L171-L175
function dispose() {
removeListeners(listeners);
inputs = [];
}
danneu
commented
Nov 28, 2015
|
Looks like Source: elm-core/Native/Runtime.js#L171-L175
|
This comment has been minimized.
Show comment
Hide comment
This comment has been minimized.
Show comment
Hide comment
TehShrike
Nov 28, 2015
This looks like what I was hoping for! I'll leave this open in case some other contributor wants to confirm, but I'll give dispose a try.
TehShrike
commented
Nov 28, 2015
|
This looks like what I was hoping for! I'll leave this open in case some other contributor wants to confirm, but I'll give |
TehShrike
closed this
Jun 4, 2016
MorganPersson
referenced this issue
Jan 31, 2017
Closed
How to teardown a module instantiated with `Elm.embed` #830
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
TehShrike commentedNov 15, 2015
I couldn't find anything in the documentation or source code.
When I need to remove a component, how am I supposed to stop it?
I don't want to have to delete the element, just clear it.
Would deleting the element from the DOM even get the job done? Would the garbage collector be able to clean up the Elm code?