MCPcopy Index your code
hub / github.com/SuperMap/iClient-JavaScript / getVersion

Function getVersion

examples/js/common.js:48–52  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

46 }
47
48 function getVersion() {
49 var pathname = window.location.pathname.replace("/en/", "/");
50 var match = pathname.match(/^\/(dev|(?:\d+\.)+\d)\/.*/);//匹配版本:dev|9.0.0
51 return match && match[1] ? match[1] : null;
52 }
53
54
55 //重置当前版本链接,不带版本号

Callers 2

setCurrentVersionFunction · 0.85
localizeFunction · 0.85

Calls 1

matchMethod · 0.80

Tested by

no test coverage detected