-
-
Notifications
You must be signed in to change notification settings - Fork 605
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: removed
camelCase
package from dependencies (#1311)
- Loading branch information
1 parent
a3ca8c0
commit ab92c82
Showing
5 changed files
with
172 additions
and
4 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
exports[`camelCase should transform 1`] = `""`; | ||
|
||
exports[`camelCase should transform: foo bar 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: __foo__bar__ 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: - 1`] = `"-"`; | ||
|
||
exports[`camelCase should transform: --__--_--_ 1`] = `""`; | ||
|
||
exports[`camelCase should transform: --foo..bar 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: --foo---bar 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: --foo---bar-- 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: --foo--1 1`] = `"foo1"`; | ||
|
||
exports[`camelCase should transform: --foo-bar 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: 1Hello 1`] = `"1Hello"`; | ||
|
||
exports[`camelCase should transform: A::a 1`] = `"a::a"`; | ||
|
||
exports[`camelCase should transform: F 1`] = `"f"`; | ||
|
||
exports[`camelCase should transform: FOO-BAR 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: FOÈ-BAR 1`] = `"foèBar"`; | ||
|
||
exports[`camelCase should transform: FOÈ-BAr 1`] = `"foèBAr"`; | ||
|
||
exports[`camelCase should transform: Hello1World11foo 1`] = `"hello1World11Foo"`; | ||
|
||
exports[`camelCase should transform: foo 1`] = `"foo"`; | ||
|
||
exports[`camelCase should transform: foo bar 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: foo bar! 1`] = `"fooBar!"`; | ||
|
||
exports[`camelCase should transform: foo bar# 1`] = `"fooBar#"`; | ||
|
||
exports[`camelCase should transform: foo bar? 1`] = `"fooBar?"`; | ||
|
||
exports[`camelCase should transform: foo_bar 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: foo--bar 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: foo-bar 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: foo-bar-baz 1`] = `"fooBarBaz"`; | ||
|
||
exports[`camelCase should transform: fooBar 1`] = `"fooBar"`; | ||
|
||
exports[`camelCase should transform: fooBar-baz 1`] = `"fooBarBaz"`; | ||
|
||
exports[`camelCase should transform: fooBarBaz-bazzy 1`] = `"fooBarBazBazzy"`; | ||
|
||
exports[`camelCase should transform: h2w 1`] = `"h2W"`; | ||
|
||
exports[`camelCase should transform: mGridCol6@md 1`] = `"mGridCol6@md"`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
import { camelCase } from "../src/utils"; | ||
|
||
describe("camelCase", () => { | ||
const data = [ | ||
"foo", | ||
"foo-bar", | ||
"foo-bar-baz", | ||
"foo--bar", | ||
"--foo-bar", | ||
"--foo---bar", | ||
"FOO-BAR", | ||
"FOÈ-BAR", | ||
"FOÈ-BAr", | ||
"--foo---bar--", | ||
"--foo--1", | ||
"--foo..bar", | ||
"foo_bar", | ||
"__foo__bar__", | ||
"foo bar", | ||
" foo bar ", | ||
"-", | ||
"fooBar", | ||
"fooBar-baz", | ||
"fooBarBaz-bazzy", | ||
"", | ||
"--__--_--_", | ||
"A::a", | ||
"1Hello", | ||
"h2w", | ||
"F", | ||
"foo bar?", | ||
"foo bar!", | ||
"foo bar#", | ||
"mGridCol6@md", | ||
"Hello1World11foo", | ||
]; | ||
|
||
for (const entry of data) { | ||
it(`should transform`, () => { | ||
expect(camelCase(entry)).toMatchSnapshot(`${entry}`); | ||
}); | ||
} | ||
}); |