How to change load order of javascript libraries in Animate

New Here ,
Nov 05, 2020 Nov 05, 2020

Copy link to clipboard

Copied

In Animate html publish templates I see the variable '$ANIMATE_CC_SCRIPTS' loads both external js libraries as well as the default index.js script.

However I need my 3rd party libraries to load before the generated 'index.js' library, is there a way to format the html template, or my fla file, to create this order.

 

example:

 

<script type='text/javascript' src='https:/s0.2mdn.net/ads/studio/cached_libs/gsap_3.5.1_min.js'></script>
<script type='text/javascript' src='https://s0.2mdn.net/ads/studio/cached_libs/createjs_2019.11.15_min.js'></script>
<script type='text/javascript' src='libs/lottie_svg.min.js'></script>
<script src="index.js"></script>

Views

72

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Community Professional ,
Nov 05, 2020 Nov 05, 2020

Copy link to clipboard

Copied

Hi.

 

Just place the script tag before the default ones in the publish template.

image.png

 

I hope it helps.

 

Regards,

JC

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 05, 2020 Nov 05, 2020

Copy link to clipboard

Copied

I don't want to add 3rd party scripts at the template level, I need different scripts for different projects. I want to add them in the Actions > Global Panel

I do this currently and it's extra work to juggle different templates.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 06, 2020 Nov 06, 2020

Copy link to clipboard

Copied

LATEST

I'm thinking now the best solution is to just remove the '$ANIMATE_CC_SCRIPTS' variable from the template and simply add 'scripts.js' to my list of 3rd party scripts.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Community Professional ,
Nov 05, 2020 Nov 05, 2020

Copy link to clipboard

Copied

Also, why are you bloating your project with GSAP? CreateJS already has a perfectly good tween library built in. Are you doing something so fancy that only GSAP can handle it?

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Nov 05, 2020 Nov 05, 2020

Copy link to clipboard

Copied

Yes I work with GSAP in many contexts, not just Adobe Animate, and often I repurpose code from one project to another. And yes GSAP has specific tools for advanced and unique animation that I use often.

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines