index.js
function _isSvgFile(file, dirPath) {
	let flag = false,
		isFile = fs.statSync(path.resolve(dirPath, file)).isFile();

	if (isFile) {   // Exclude directory
		if (path.extname(file) === '.svg') {    // Only accept files which with svg suffix
			flag = true;
		}
	}
	return flag;
}
function _isSvgFile(file, dirPath) {
	let flag = false,
		isFile = fs.statSync(path.resolve(dirPath, file)).isFile();

	if (isFile) {   // Exclude directory
		if (path.extname(file) === '.svg') {    // Only accept files which with svg suffix
			flag = true;
		}
	}
	return flag;
}
function _isSvgFile ( file , dirPath ) { let flag = false , isFile = fs . statSync ( path . resolve ( dirPath , file ) ) . isFile ( ) ; if ( isFile ) { // Exclude directory if ( path . extname ( file ) === '.svg' ) { // Only accept files which with svg suffix flag = true ; } } return flag ; }
Determine whether the current file is an svg file

@param  {String} file
@param  {String} dirPath
@return {Boolean}
Determine whether the current file is an svg file