-
Notifications
You must be signed in to change notification settings - Fork 3
JavaScript Loading
thepian edited this page Oct 5, 2012
·
4 revisions
The default way for a script to be loaded into the page is while the page is being loaded. Regular HTML script tags are loaded one at a time as the page progresses loading.
Using EssentialJS other options are,
- After page load (pastload)
- After user authenticated (pastuser)
- Before other after page load scripts (preload)
To use one of these options add a link element,
<link src="js/knockout.js" rel="pastload" type="text/javascript">
The script will be loaded by a dynamically added script tag. The script will be monitored and the page launching will be postponed until the script is loaded.