httpclient.post in angular code example
Example: angular httpclient post body
ngOnInit() {
this.http.post<any>('https://jsonplaceholder.typicode.com/posts', { title: 'Angular POST Request Example' }).subscribe(data => {
this.postId = data.id;
})
}