-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Remote assets disappear once page is cached #2445
Comments
i'm aware of this particular issue, and will look at it shortly. |
Ok, please test the fix. |
Works perfectly now when adding via Gantry, however nothing seems to have changed from my table above when doing it via twig. Just to check what I'm doing there: in the Admin panel, I've been enabling twig processing for the target page, then adding the above twig to the top of the page. |
I'm not sure you tested with all the changes, because i've tested this (outside of Gantry) and it works perfect in all combinations. here's:
After several reloads with cache on... I feel very confident this issue is resolved. |
btw my Twig:
|
I'm still seeing it, here's exactly what I'm doing in an empty folder on my server: Then in admin, turn on debugger and edit default home page so it is as follows:
Sorry if I'm doing something wrong, I'd normally just do it through gantry, but thought a theme-non-dependent test would be useful. |
Ok, well there's your problem. You are adding the asset in your content, and the content get's cached and the Twig will get lost. If you want to do it that way you need to set:
In your frontmatter. |
Ah, thanks, I don't often use twig so I forgot! |
Potentially related to previous issues #101 and #770, and branching from #2216, remote assets are(in some cases) only output upon the first page load after a cache clear, completely absent from any subsequent refreshes.
On a clean install of 1.6.3 (plus admin & gantry, also verified before installing gantry), I tested adding FA5 CSS via twig to a single page (
{% do assets.addCss('https://use.fontawesome.com/releases/v5.8.1/css/all.css') %}
) and via Gantry > Page Settings > Assets to the whole site with different pipelining options selected, the results of which are summarised here:<link>
present in first load only<link>
always present<link>
present in first load only<link>
present in first load onlyThe text was updated successfully, but these errors were encountered: