-
Notifications
You must be signed in to change notification settings - Fork 0
feat: Add slugify utility #72
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Coverage Report
File Coverage
|
||||||||||||||||||||||||||||||||||||||
| expect(output).toBe("hello-world-this-is-a-test"); | ||
| }); | ||
|
|
||
| test("특수 문자가 포함된 문자열을 올바르게 변환한다.", () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이 테스트 케이스도 궁금할 것 같은데 추가가 가능하실까요?!
test("slug 형태의 문자열은 그대로 slug 형태로 반환한다.", () => {
const input = "Hello-World";
const output = slugify(input);
expect(output).toBe("hello-world");
});
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
오!! 한 번 테스트해볼게요!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
잘 되네요 :)
klmhyeonwoo
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
고생하셨습니다! URL에 잘 쓰일 것 같은 유틸리티네요!
저는 지금 유용한 유틸함수가 왠만하면 거의 다 들어가서 조금 생각을 해봐야할 것 같아요!
그래서 이번 PR 머지 후 릴리즈 부탁드려도 될까요!
넵!! 알겠습니다 ^^7 |
맞지요 맞지요 lodash를 이기는 그날까지,, |
edfcbd0 to
88bbd3e
Compare
Description
URL 친화적인 문자열 변환을 위한
slugify함수를 추가했습니다.블로그 포스트 URL, 파일명 생성, SEO 친화적 링크 생성 등에 활용할 수 있으며,
한글을 포함한 다국어 문자열을 안전하게 처리합니다.
새로운 기능
stringUtil.slugify()함수 추가slug형태로 변환구현방식