Performance and compatibility
SDK size, how it loads, extra requests, impact on the checkout and supported browsers.
The SDK is built not to slow down your checkout: the synchronous part is small and makes no network requests, and the rest loads asynchronously. This page shows the real numbers and what the SDK does on each page load.
Size
| Part | Uncompressed size | Gzipped size | How it loads |
|---|---|---|---|
| Bootstrapper | 4.3 KB | ~1.9 KB | Inline in the HTML, synchronous. |
shield.js SDK | 60 KB | ~19.6 KB | File from the CDN, with async. The CDN serves it with Brotli (~17 KB). |
The bootstrapper adds about 4.3 KB to each page's HTML before your server's compression. shield.js is cached in the
browser and on the CDN.
Loading
- Bootstrapper: runs in under 1 ms and makes no requests.
shield.js: loaded withasync, it doesn't block the parser or page rendering.- Initialization: the SDK loads the store's configuration before starting detections. The checkout doesn't wait for the SDK.
The SDK is built to never break the page: all of its code runs guarded against errors, and telemetry sends don't block anything.
Requests per page load
| Request | When | Note |
|---|---|---|
shield.js from cdn.proteside.com | once | Usually served from cache. |
Store configuration from app.proteside.com | once | |
GET of the page itself | once, and on every pageChanged() | Reads the security headers. See the warning in CSP and headers. |
GET of the page's external scripts | when needed | To compute the content hash. Uses the browser cache whenever possible. |
Event delivery to app.proteside.com | in small batches, while there are events | One final send when the customer leaves the page. |
Ongoing processing
While the page is open, the SDK periodically checks the payment fields and the displayed payment codes, and watches for page changes to detect new scripts and payment codes. This work is lightweight and needs no tuning.
Supported browsers
| Browser | Minimum version |
|---|---|
| Chrome | 80 |
| Edge | 80 |
| Firefox | 78 |
| Safari | 14 |
Use HTTPS on your checkout
Some checks, such as trusted recipient verification, depend on browser features that are only available on HTTPS pages. Use HTTPS on every payment page.