Which event should be used to start the code?
See original GitHub issueWhen I used window.addEventListener('load', () => app(...))
the subs
didn’t work correctly, as they never seemed to receive the event. How should we handle this without adding the <script>
to the last line of the HTML?
Note: It should work with both <script async ...>
and <script>
if possible.
Issue Analytics
- State:
- Created 7 years ago
- Comments:32 (15 by maintainers)
Top Results From Across the Web
Introduction to events - Learn web development | MDN
Events are actions or occurrences that happen in the system you are programming, which the system tells you about so your code can...
Read more >Introduction to browser events - The Modern JavaScript Tutorial
An event is a signal that something has happened. All DOM nodes generate such signals (but events are not limited to DOM).
Read more >Handling Events :: Eloquent JavaScript
Though we have ignored it so far, event handler functions are passed an argument: the event object. This object holds additional information about...
Read more >What is an event handler and how does it work? - TechTarget
An event handler dictates the action that takes place in a software program after an event. In this article, we explain how event...
Read more >JavaScript Events - W3Schools
HTML events are "things" that happen to HTML elements. When JavaScript is used in HTML pages, JavaScript can "react" on these events.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@dodekeract Ah, what @tunnckoCore said. Good job on catching that!
@jbucaran That’s one way to put it, yes.