typeorm embedded entity

Solutions on MaxInterview for typeorm embedded entity by the best coders in the world

showing results for - "typeorm embedded entity"
Alia
24 Jun 2016
1import {Entity, PrimaryGeneratedColumn, Column} from "typeorm";
2
3export class Name {
4    @Column()
5    first: string;
6
7    @Column()
8    last: string;
9}
10
11@Entity()
12export class User {
13    @PrimaryGeneratedColumn()
14    id: string;
15
16    @Column(type => Name)
17    name: Name;
18}
similar questions
typeorm upsert