Skip to content
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

Single-word lower/pascal case? #4

Open
jrr opened this issue May 25, 2023 · 0 comments
Open

Single-word lower/pascal case? #4

jrr opened this issue May 25, 2023 · 0 comments

Comments

@jrr
Copy link

jrr commented May 25, 2023

Thanks for this project! It's been really helpful on my project to map between a couple different systems that have different capitalization conventions.

Specifically, I've used pascalCase and camelCase, but for single words without spaces. (e.g., converting Foobar <-> foobar)

This works fine, but I wonder if it would make sense to have different named operations, that don't have space-inserting behavior. E.g.:

const str: "foobar" = lowerCase("FooBar");
const str : "Foobar" = initialCapitalCase("fooBar");

I recognize that there are so many specific combinations, that it could get out of hand quickly (and be difficult to name them all). Maybe there's another way to design the API? (composable functions/types?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant