(path)
| 929 | // /resource/ <= /resource/index.html |
| 930 | // /resource <= resource.html |
| 931 | getUrlsFromFilePath(path) { |
| 932 | if(this.dir === ".") { |
| 933 | path = `/${path}` |
| 934 | } else { |
| 935 | path = path.slice(this.dir.length); |
| 936 | } |
| 937 | |
| 938 | let urls = []; |
| 939 | urls.push(path); |
| 940 | |
| 941 | if(path.endsWith(`/${this.options.indexFileName}`)) { |
| 942 | urls.push(path.slice(0, -1 * this.options.indexFileName.length)); |
| 943 | } else if(path.endsWith(".html")) { |
| 944 | urls.push(path.slice(0, -1 * ".html".length)); |
| 945 | } |
| 946 | |
| 947 | return urls; |
| 948 | } |
| 949 | |
| 950 | // returns [{ url, inputPath, content }] |
| 951 | getBuildTemplatesFromFilePath(path) { |
no outgoing calls
no test coverage detected