Answers for "check if path is absolute js"

0

check if path is absolute js

var path = require('path');

console.log(path.isAbsolute('/test/demo_path.js')); //true
console.log(path.isAbsolute('test/demo_path.js')); //false
console.log(path.isAbsolute('C:\\test\\demo_path.js')); //true
Posted by: Guest on June-21-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language