Lines Matching refs:path
69 function getVersionFromPath(path: string) {
70 const pathParts = path.split(/\//);
79 function isVersionDocumented(path: string) {
80 return supportedVersions.includes(getVersionFromPath(path));
83 function pathIncludesHtmlExtension(path: string) {
84 return !!path.match(/\.html$/);
87 function pathIncludesIndexHtml(path: string) {
88 return !!path.match(/index\.html$/);
97 function isVersionedPath(path: string) {
98 return !!path.match(new RegExp(VERSIONED_PATH_PATTERN));
102 function replaceVersionWithLatest(path: string) {
103 return path.replace(new RegExp(VERSION_PART_PATTERN), 'latest');
116 function pathRequiresVersioning(path: string) {
117 const isExpoSdkPage = path.match(new RegExp(SDK_PATH_PATTERN));
118 const isExpoSdkIndexPage = path.match(new RegExp(VERSIONED_PATH_PATTERN + '/$'));
119 const isReactNativeApiPage = path.match(new RegExp(REACT_NATIVE_PATH_PATTERN));
124 function removeVersionFromPath(path: string) {
125 return path.replace(new RegExp(VERSIONED_PATH_PATTERN), '');
129 function endsInNull(path: string) {
130 return !!path.match(/\/null$/);