Open danfox01 opened 5 years ago
I think with the current layout the way to do this would be to put the json files in the constants file (if they aren't already there) for the site, and remove the constants from master.js and include it separately.
@danfox01 a fix has been moved to dev for testing.
@danfox01 @tmccoy529 what is the status of this, dynamic stylesheet was blocking this before?
Um.... hang on I'm confused. Is this BCPL issue separate from the BCG cache busting issue we were looking at last week: https://github.com/baltimorecounty/baltimorecountymd.gov-assets/issues/168?
@tmccoy529 since this is bcpl, i think this is good, we just need to release this change?
Yes, we will just need to copy the constants.js file out to SE prod and update the templates with its location.
@tmccoy529 looks like this never made it to prod either?
Always a fun topic.
@danfox01 @tmccoy529 @sdurphy this was not released tonight because I failed to remember that Polaris would also need updated. Luckily we didn't move anything. We will come up with a plan tomorrow.
@danfox01 @martypowell @sdurphy I was able to add the reference for the constants.min.js file to the site.master file for Polaris today. Upon testing, the constants file is loaded on ils-test. I jumped through some of the catalog searching and got no javascript errors but I think putting more eyes on this would be a good idea.
@jdomasky can you please test this as well? I think a brief smoke test is fine. Any issues should jump out pretty quickly. We're just looking to see if there are any JS issues in ILS-TEST.
@danfox01 OK, will test on Friday as well.
A brief test was completed. There were no JavaScript errors. However, there seems to be a bug with the contraster in ILS-Test:
Current behavior: If you toggle on high contrast on catalog home (http://ils-test.bcpl.lib.md.us/polaris), then perform a search, regular contrast is restored.
Expected behavior: High contrast should retain its state on different pages and across sessions.
In Polaris prod, if you toggle on high contrast on catalog home, then perform a search, high contrast is retained.
@tmccoy529 you weren't tagged in Jason's reply. Just want to make sure you saw this. Back to you to evaluate.
@danfox01 thanks, looking into it.
@tmccoy529 Just want to document what we discussed in the release meeting today. This issue is still under investigation, but a lower priority than BaltCoGo, correct?
@danfox01 That is correct
When JSON files are updated, the data remains cached until the user performs a hard refresh. This is problematic when staff expect to see instant changes, and for the public who shouldn't need to clear their own cache to see the latest version of the site.
Our workaround has been to update a number of query strings in the master JS, which is time consuming and a little dangerous. Since, the intention of JSON is to allow updates without developer intervention, it seems like we need solution to more easily break the cache for JSON files.
This applies to all sites in SE ... see related issue for BCG: https://github.com/baltimorecounty/baltimorecountymd.gov-assets/issues/168