index.js
function(filePath, currentPath){
	if(/^(?:\/|[a-zA-Z]:(?:\/|\\))/.test(filePath)){ // Is the path absolute?
		filePath = path.normalize(filePath);
	}else{ // Relative paths need to be resolved first
		filePath = path.resolve(currentPath, filePath);
	}
	return filePath;
}
function(filePath, currentPath){
	if(/^(?:\/|[a-zA-Z]:(?:\/|\\))/.test(filePath)){ // Is the path absolute?
		filePath = path.normalize(filePath);
	}else{ // Relative paths need to be resolved first
		filePath = path.resolve(currentPath, filePath);
	}
	return filePath;
}
function ( filePath , currentPath ) { if ( / ^(?:\/|[a-zA-Z]:(?:\/|\\)) / . test ( filePath ) ) { // Is the path absolute? filePath = path . normalize ( filePath ) ; } else { // Relative paths need to be resolved first filePath = path . resolve ( currentPath , filePath ) ; } return filePath ; }
Parse absolute and relative path strings to a full path
@param {string} filePath
@param {string} currentPath
@returns {string}
Parse absolute and relative path strings to a full path