typeorm embedded code example
Example: typeorm embedded entity
import {Entity, PrimaryGeneratedColumn, Column} from "typeorm";
export class Name {
@Column()
first: string;
@Column()
last: string;
}
@Entity()
export class User {
@PrimaryGeneratedColumn()
id: string;
@Column(type => Name)
name: Name;
}