blakeembrey / change-case

Convert strings between camelCase, PascalCase, Capital Case, snake_case and more
MIT License
2.25k stars 96 forks source link

Replace dot-case with no-case dependency #226

Closed linkvt closed 2 years ago

linkvt commented 3 years ago

Hi, thanks for the nice and lean libraries!

When adding the snake-case dependency to my project I noticed, that it referenced dot-case which referenced no-case, this seemed a bit strange, why would I need dot-case in the snake-case lib. From what I see now, dot-case just calls no-case and provides no real benefit to snake-case - and also possibly others - as the dot-case separator is just overwritten.

Do you mind a PR from me where the dot-case dependency in snake-case (and possibly others) is replaced by no-case if no features are added?

Relevant snake-case section: https://github.com/blakeembrey/change-case/blob/c24a0e18044bf77d9e824e93f04f7eb4e2151230/packages/snake-case/src/index.ts#L6-L9 Relevant dot-case section: https://github.com/blakeembrey/change-case/blob/c24a0e18044bf77d9e824e93f04f7eb4e2151230/packages/dot-case/src/index.ts#L6-L9

Thanks, Vincent

blakeembrey commented 3 years ago

Absolutely, go for it! I think I discovered this myself the other day but didn't get around to fixing it 😓

linkvt commented 3 years ago

FYI @blakeembrey, I created a PR for this.