Versioning
This describes how Mosaic Platform SDK is versioned.
Semantic versioning
The Platform SDK follows the semantic versioning standard. This means each version number is comprised of X.Y.Z, where:
- X corresponds to a major version
- Y correponds to a minor version
- Z corresponds to a patch
With the new release, the SDK version number is updated incrementally depending on the changes introduced in the SDK. A new version includes new features, bugfixes, and occasionally breaking changes. For information on SDK updates, refer to Changelog.
When loading an SDK, you can decide which version to target. There are several options and considerations when it comes to specifying a version.
Using the latest v1 (recommended)
To ensure your integration isn't affected by breaking changes but still includes fixes and new features, consider targeting a specific major version (X.x
). Your code will load the latest available minor version and patch released for this major version. For example, if 1.15.0
is the latest SDK version available, then specifying the version as shown below will load 1.15.0
, then 1.15.1
, then 1.16.0
and 1.16.1
once they are released but won't load 2.0
, etc.
The example below points to the major version range.
<script src="https://platform-websdk.transmitsecurity.io/platform-websdk/1.x/ts-platform-websdk.js" defer="true" id="ts-platform-script"></script>
npm install @transmitsecurity/platform-web-sdk@^1
yarn add @transmitsecurity/platform-web-sdk@^1
Using a minor version range
Targeting the latest patch for a specific minor version (X.Y.x
) brings extra stability to your integration. In this case, the latest SDK within the minor version range will be installed. For example, if 1.13.6
is currently the latest version available for 1.13
, then specifying the version as shown below will load 1.13.6
, and then 1.13.7
and 1.13.8
once released. Versions such as 1.14.0
, 1.14.2
, or 1.15.0
won't be loaded.
<script src="https://platform-websdk.transmitsecurity.io/platform-websdk/1.13.x/ts-platform-websdk.js" defer="true" id="ts-platform-script"></script>
npm install @transmitsecurity/platform-web-sdk@~1.13.6
yarn add @transmitsecurity/platform-web-sdk@~1.13.6
Using a specific version
You may prefer to target a specific SDK version (X.Y.Z
) and perform SDK updates upon explicit testing and verification. Below is an example that invokes a specific version.
<script src="https://platform-websdk.transmitsecurity.io/platform-websdk/1.13.7/ts-platform-websdk.js" defer="true" id="ts-platform-script"></script>
npm install @transmitsecurity/platform-web-sdk@1.13.7
yarn add @transmitsecurity/platform-web-sdk@1.13.7