提交 7728212b 编写于 作者: F Filipa Lacerda

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

Remove slugify text utility

See merge request gitlab-org/gitlab-ce!27290
......@@ -43,13 +43,6 @@ export const pluralize = (str, count) => str + (count > 1 || count === 0 ? 's' :
*/
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
* @param {String} str
......
......@@ -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', () => {
it('returns string with first letter capitalized', () => {
expect(textUtils.capitalizeFirstCharacter('gitlab')).toEqual('Gitlab');
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册