feat(utils): addDashesToSpaces utils

This commit is contained in:
Carlos Garcia Ortiz karliatto
2023-11-07 12:32:55 +01:00
committed by Carlos García Ortiz
parent ffcfde3bb5
commit 116c3a9274
2 changed files with 4 additions and 0 deletions

View File

@@ -0,0 +1,3 @@
export const addDashesToSpaces = (inputString: string): string =>
// Use a regular expression to replace spaces with dashes
inputString.replace(/\s+/g, '-');

View File

@@ -34,3 +34,4 @@ export * from './urlToOnion';
export * as versionUtils from './versionUtils';
export * as xssFilters from './xssFilters';
export * from './getLocaleSeparators';
export * from './addDashesToSpaces';