Self-Referencing ManyToMany Relationship TypeORM

后端 未结 2 1460
半阙折子戏
半阙折子戏 2021-02-14 17:16

I have just started using TypeORM and I\'m struggling getting the following relationship to work:

User->Friends, whereas a Friend is also a User Object. My getters, getF

2条回答
  •  北荒
    北荒 (楼主)
    2021-02-14 18:11

    I hope someone understands my question

    Yeah, here is the problem. I don't know what are trying to do. Friend is a separate class or it's still User->User[] relation?

    Maybe this will help you: https://typeorm.github.io/tables-and-columns.html#closure-table

提交回复
热议问题