Angular Forms: Useful Tips

Disagree with the DTO part.
This is TS which compiled down to js, this is not java or c#.
You can find a lot of “you dont need a ‘new entityClass()’ in ts/js” via google.
Prefer functional way and let Typescript doing the type checking.

export interface Article {
  title: string;
  tags: string;
  date: string;
  referenceIds: number[];
}

const article: Article = {
  title: this.formValue.title,
  tags: this.formValue.tags.join(','),
  date: this.formValue.date.toISOString(),
  referenceIds: this.formValue.referenceIds && formValue.referenceIds.length > 0 ? this.formValue.referenceIds : null
}

Well, if I need to create multiple article instances, it’s easier to call new Article(title, tags, /* rest */) than copy-paste the declaration. You may think “well then we can just create a function to do that”, to which I say we then would have an interface and a function, possibly in separate files, when we could just have a class with a constructor that encapsulates both the type definition and the initialization logic (which definitely belong together). I don’t think writing classes is always a bad idea; when we talk about specific business-logic items like data objects (rather than abstract things like components, directives and etc) classes actually do a great job.