Commit 7728212b authored by Filipa Lacerda's avatar Filipa Lacerda

Merge branch 'fe-remove-slugify' into 'master'

Remove slugify text utility

See merge request gitlab-org/gitlab-ce!27290
parents 539ac258 e42ecb1c
...@@ -43,13 +43,6 @@ export const pluralize = (str, count) => str + (count > 1 || count === 0 ? 's' : ...@@ -43,13 +43,6 @@ export const pluralize = (str, count) => str + (count > 1 || count === 0 ? 's' :
*/ */
export const dasherize = str => str.replace(/[_\s]+/g, '-'); export const dasherize = str => str.replace(/[_\s]+/g, '-');
/**
* Removes accents and converts to lower case
* @param {String} str
* @returns {String}
*/
export const slugify = str => str.trim().toLowerCase();
/** /**
* Replaces whitespaces with hyphens and converts to lower case * Replaces whitespaces with hyphens and converts to lower case
* @param {String} str * @param {String} str
......
...@@ -49,12 +49,6 @@ describe('text_utility', () => { ...@@ -49,12 +49,6 @@ describe('text_utility', () => {
}); });
}); });
describe('slugify', () => {
it('should remove accents and convert to lower case', () => {
expect(textUtils.slugify('João')).toEqual('joão');
});
});
describe('capitalizeFirstCharacter', () => { describe('capitalizeFirstCharacter', () => {
it('returns string with first letter capitalized', () => { it('returns string with first letter capitalized', () => {
expect(textUtils.capitalizeFirstCharacter('gitlab')).toEqual('Gitlab'); expect(textUtils.capitalizeFirstCharacter('gitlab')).toEqual('Gitlab');
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment