All Collections
What's New
Updates to the main trustmark code | March 2020
Updates to the main trustmark code | March 2020
Nick Hemenway avatar
Written by Nick Hemenway
Updated over a week ago

In March 2020 we made updates to simplify and streamline the main trustmark code.

Previously our code used jQuery, a Javascript library that includes some scripts used by our trustmarks, but also contains many more scripts the trustmarks don’t need to operate. These unutilized scripts could have caused minor trustmark loading delays in some situations. Additionally, some customers using jQuery on their own sites may have been utilizing a different version than us, which could have caused compatibility issues with our trustmarks.

To eradicate these issues, we removed jQuery from the main code. This means a few things for our customers.

  1. Trustmark file size is now 74% smaller.

  2. Trustmarks will now load slightly faster, particularly if your site is viewed from a slower or older computer or browser.

  3. There are no longer compatibility issues for sites using jQuery in their own code.

Additionally, we’ve added a new way the trustmarks can be loaded. Previously, trustmarks were only rendered once at the initial time the page was loaded. This caused issues for sites utilizing elements such as a 1-page dynamic checkout, where multiple checkout steps occur within one page. In this scenario, our trustmarks were only able to load on the first step of checkout.

With this new update, instead of just one initial scan, we’ve created an alternate code snippet you can add to your site that will allow continuous scans of a page, so that it’s always searching for places to display the trustmarks. This means that trustmarks can now be displayed in multiple steps of a dynamic checkout, and within other dynamic elements your site may utilize. This additional code snippet is optional and we recommend you only add it to dynamic areas of your site.

To enable continuous scanning, instead of adding the following code snippet as normal:

<script src="" async></script>

Instead use:

<script src="" id="trustedsite-code" data-rescan="1" async></script>
Did this answer your question?