Versioning your Viewer-based app

November 26, 2018

We talked about versioning your Viewer code before (see here) and showed how to do with a suffix, e.g.: ?v=v6.0

Starting on version 6 we can specify it on the URL, which allows us better control over the served file. The resulting HTML should look like: 

<link rel="stylesheet" href="" type="text/css">
<script src=""></script>

As we use Semantic Version we can replace minor and patch versions with * (star), resulting in something like:

<link rel="stylesheet" href="*/style.min.css" type="text/css">
<script src="*/viewer3D.min.js"></script>

The above will load any new minor or patch version from 6, which today (as of November 26) would be 6.3.1. You can also use 6.3.* to specify the minor or 6.3.1 to completely specify the version. 

Posts by author

Augusto Goncalves
Developer Advocate, Autodesk

Developer Advocate at Autodesk since 2008, working with both desktop and web/cloud apps using top technologies, like C#, JavaScript, NodeJS and any other that can solve problems and improve workflo