ui: don't remove dashes when auto generating slug

This commit is contained in:
Jens Langhammer
2020-02-20 17:13:50 +01:00
parent 3c04afa31f
commit 14e0a17dbc
2 changed files with 2 additions and 5 deletions

View File

@ -1,9 +1,8 @@
function convertToSlug(Text) {
return Text
.toLowerCase()
.replace(/[^\w ]+/g, '')
.replace(/ +/g, '-')
;
.replace(/[^\w ]+/g, '-')
.replace(/ +/g, '-');
}