According to MDN,
The DOMContentLoaded event is fired when the initial HTML document has been completely loaded and parsed, without waiting for stylesheets, images, and subframes to finish loading.
Note: Synchronous JavaScript pauses parsing of the DOM.
In your case, the way you are referencing the external Javascript file, it is treated as synchronous, i.e. it will be fetched and loaded before the elements after that will be parsed.
So, answer is, yes, it will always execute - as long as the external JS file is available to the browser.
If you had indicated that browser should attempt to download the script asynchronously (by setting async
attribute to true), then the event may or may not trigger the callback you register.