Closed matyax closed 1 year ago
I am not a big fan of reinventing the wheel. Obviously importing whole lodash just for trimEnd
isn't great, but what about using https://www.npmjs.com/package/lodash.trimend?
I really don't think we need any dependency for 3 lines of code.
Additionally, we would have to either:
I really don't think we need any dependency for 3 lines of code.
Next method we wanna use we say the same :D But also fine for me right now - nevertheless using dependencies shouldn't be a great show stopper.
Though, it's fine for me to not use any dependency for this.
We can definitely introduce dependencies in the near future if we need it. For now let's roll with this if you don't mind. Thanks!
While working on adding a new grammar I wanted to use the usual tree-viz and I noticed it was failing. I looked deeper and saw that it was failing because it couldn't find lodash.
IMO adding lodash as a dependency is not right, as it forces consumers of this library to have this dependency, and all that just for a
trimEnd
function.In this PR I'm removing lodash and replacing it with a custom
trimEnd
implementation.