nestjs-i18n icon indicating copy to clipboard operation
nestjs-i18n copied to clipboard

Opt out of class-validator

Open gmanavarro opened this issue 8 months ago • 0 comments

Clear and concise description of the problem

Just recently I started looking for an implementation of i18n for Nestjs and found this library. It seems pretty useful so far, but I tried to start using it in my project and it's throwing an error from I18nService regarding the class-validator library. I guess it's a required dependency and I need to install it for nestjs-i18n to work. Since I'm using zod and I'm not planning to use class-validator, I wanted to know if it would be possible to opt out of the features using class-validator.

Suggested solution

Add some kind of option in the I18nModule config to opt out of using class-validator related features.

Alternative

An alternative would be to just install class-validator and get over it, but I don't think I should be installing a dependency I have no use for just for the sake of a dependency requirement of features I will not be using.

Additional context

No response

Validations

  • [X] Follow our Code of Conduct
  • [X] Read the Contributing Guide.
  • [X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.

gmanavarro avatar Jun 10 '24 00:06 gmanavarro