mirror of
https://github.com/coreui/coreui-icons.git
synced 2025-08-04 15:57:28 +02:00
fix: remove double prefixes
This commit is contained in:
@@ -36,7 +36,7 @@ mkdirp('sprites/', function(err) {
|
|||||||
const computedContent = content.replace(/(<svg([^>]+)>)|(<\/svg>)/ig, '')
|
const computedContent = content.replace(/(<svg([^>]+)>)|(<\/svg>)/ig, '')
|
||||||
.replace(/\n/g, '').replace(/"/g, '\'')
|
.replace(/\n/g, '').replace(/"/g, '\'')
|
||||||
.replace('<!-- Generated by IcoMoon.io -->', '')
|
.replace('<!-- Generated by IcoMoon.io -->', '')
|
||||||
symbol = `<symbol id="${prefixes[setName]}${svg.replace('.svg', '').toLowerCase()}" viewBox="${viewBox}">\n${computedContent}\n</symbol>`
|
symbol = `<symbol id="${svg.replace('.svg', '').toLowerCase()}" viewBox="${viewBox}">\n${computedContent}\n</symbol>`
|
||||||
idx === svgs.length - 1 ? symbols.push(symbol) : symbols.push(`${symbol}\n`)
|
idx === svgs.length - 1 ? symbols.push(symbol) : symbols.push(`${symbol}\n`)
|
||||||
})
|
})
|
||||||
fs.writeFile(
|
fs.writeFile(
|
||||||
|
Reference in New Issue
Block a user