-
Notifications
You must be signed in to change notification settings - Fork 5.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Moves <script> tags to end of <body> #6375
Conversation
So cool! |
Moves <script> tags to end of <body>
all scripts are after start of the body tag, not the end. what is the different between in head? <script type="text/javascript">**meteor_runtime_config** = JSON.parse(decodeURIComponent("%7B%22meteorRelease%22%3A%22METEOR%401.3.1%22%2C%22meteorEnv%22%3A%7B%22NODE_ENV%22%3A%22development%22%2C%22TEST_METADATA%22%3A%22%7B%7D%22%7D%2C%22PUBLIC_SETTINGS%22%3A%7B%7D%2C%22ROOT_URL%22%3A%22http%3A%2F%2Fcubes.legal%22%2C%22ROOT_URL_PATH_PREFIX%22%3A%22%22%2C%22appId%22%3A%22432alqykmnfz1yh9mh1%22%2C%22autoupdateVersion%22%3A%22a9485d025cf3aa02e94156eb731c3dadc936625c%22%2C%22autoupdateVersionRefreshable%22%3A%222d9889120823a66812793b07955a3c1de86945dd%22%2C%22autoupdateVersionCordova%22%3A%22none%22%7D"));</script>
|
Hey im late to the party on this, but we had some scripts in head. What do you suggest we do for jquery plugins loaded in async in head...now they dont have jquery refs |
What do you mean? You should always wrap use of your jQuery modules inside |
Or are you saying that because now loading of jQuery itself has been put at the end, if you just add scripts to the head, jQuery itself is not yet loaded at that point? Maybe add those |
Hey @abhiaiyer91 . I don't quite understand the problem. Could you post a brief, illustrative code sample? Edit: Feel free to disregard this question if we've already solved the issue for you via the Develop Subscription. |
@mitar @zol Mitar, sorry for being vague. Yes exactly what you said, we had scripts in head loading async already. Now jquery has moved to the end, so we got some reference errors. What we ended up doing was adding We don't want to have these 3rd party libs in our bundle, as it is big already... |
Rather than include our bundle from , include it at the end of . This way, code can make use of the new
dynamicHead
feature to add loading html into the boilerplate. (as requested by #3860)