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

capitalize rules are too aggressive #396

Closed
GavinJoyce opened this issue Apr 5, 2019 · 3 comments
Closed

capitalize rules are too aggressive #396

GavinJoyce opened this issue Apr 5, 2019 · 3 comments
Assignees

Comments

@GavinJoyce
Copy link
Member

Looking at the tests and implementation, it seems that characters following forward slashes are meant to be capitalized:

"privateDocs/ownerInvoice".capitalize() => "PrivateDocs/OwnerInvoice"

This also currently happens for multiple forward slashes though which seems like a bug to me:

"the url is http://www.ember.com/".capitalize() => "The url is http://Www.ember.com/"
(note the Www)

@GavinJoyce
Copy link
Member Author

GavinJoyce commented Apr 5, 2019

@locks pointed me to the RFC to deprecate Ember.String and supporting issue.

Screen Shot 2019-04-05 at 16 21 02

I'll read those and come back with a plan

@locks locks self-assigned this Apr 19, 2020
@locks locks transferred this issue from emberjs/ember.js Jul 22, 2023
@NullVoxPopuli
Copy link
Contributor

I've been using change-case https://github.com/blakeembrey/change-case

does that have better behavior? (or more customizable behavior?)

@locks
Copy link
Contributor

locks commented Jul 23, 2023

I think that's a good enough alternative now that @ember/string isn't a core module.

@locks locks closed this as completed Jul 23, 2023
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

Successfully merging a pull request may close this issue.

3 participants