Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
$.tap(file => {
const fileName = path.basename(file.path);
const className = lowerCase(headerCase(fileName.replace('.js', '')));
return gulp
.src(`${DIST_FOLDER}/${fileName}`)
.pipe(
$.replace(
'classNameString',
`{...props} className={\`${CLASSNAME} ${CLASSNAME}-${className} \${props.className\}\`}`
)
)
.pipe($.replace(/xmlns:xlink=".+?"/g, ``))
.pipe($.replace(/xlink:href=".+?"/g, ``))
.pipe($.replace('fill-rule=', 'fillRule='))
.pipe($.replace('fill-opacity=', 'fillOpacity='))
.pipe($.prettier())
.pipe(gulp.dest(DIST_FOLDER))
.pipe(gulp.dest(LIB_FOLDER));