feature/nodejs_implementation #1
1 changed files with 4 additions and 9 deletions
|
@ -123,18 +123,13 @@ function extToFormat(ext: string): keyof FormatEnum {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Determine whether the given `path` is a http(s) URL. This method
|
* Check if a path is a web URI.
|
||||||
* accepts a string value and a URL instance.
|
|
||||||
*
|
*
|
||||||
* inspiration:
|
|
||||||
* Marcus Pöhls
|
|
||||||
* https://futurestud.io/tutorials/node-js-check-if-a-path-is-a-file-url
|
|
||||||
*
|
|
||||||
* @param {String|URL} path
|
* @param {String|URL} path
|
||||||
* The path to check.
|
* The path to check.
|
||||||
*
|
*
|
||||||
* @returns {Boolean}
|
* @returns {Boolean}
|
||||||
* True if the path is a web URI, false otherwise.
|
* Whether the path is a web URI.
|
||||||
*/
|
*/
|
||||||
function isWebURI(path: string | URL): boolean {
|
function isWebURI(path: string | URL): boolean {
|
||||||
try {
|
try {
|
||||||
|
|
Loading…
Reference in a new issue