Typeorm: What's difference between @Unique decorator and { unique: true } in column options?

前端 未结 0 1121
天涯浪人
天涯浪人 2021-02-13 13:54

In Typeorm you have the possibility to set a unique flag in the column options, or to set column(s) to unique for the entity.

When would you use what, and what\'s the dif

相关标签:
回答
  • 消灭零回复
提交回复
热议问题