install ng2-file-upload
npm i ng2-file-upload --save
component.html
<label class="image-upload-container btn btn-bwm">
  <span>Select New Image</span>
  <div *ngIf="selectedFile">
    <img src="{{selectedFile.src}}" class="img_profile img-circle" >
   </div>
  <input #imageInput
         type="file"
         accept="image/*" ng2FileSelect [uploader]="uploader"
         (change)="processFile(imageInput)" name="newImage">
</label>
 
 
app.module.ts
import { FileSelectDirective } from 'ng2-file-upload';
//in declaration
declarations: [ ...,
FileSelectDirective,
... ],
component.ts
 import { Component, OnInit,ViewContainerRef,ElementRef,ViewChild } from '@angular/core';
import {  FileUploader } from 'ng2-file-upload/ng2-file-upload';
//Set api url
const URL = 'http://127.0.0.1:3000/users/uploadFile';
//Apply for preview. add before export class
class ImageSnippet {
pending: boolean = false;
  status: string = 'init';
 constructor(public src: string, public file: File) {}
}
 @Component({
  selector: 'app-imageupload',
  templateUrl: './imageupload.component.html',
  styleUrls: ['./imageupload.component.css']
})
//export class
export class ImageuploadComponent implements OnInit {
  public name:any
  constructor() { }
    selectedFile: ImageSnippet;
   
  ngOnInit() {
    this.uploader.onAfterAddingFile = (file)=> { file.withCredentials = false; };
    this.uploader.onCompleteItem = (item:any, response:any, status:any, headers:any) => {
      console.log("ImageUpload:uploaded:", item, status, response);
     };
  }
  processFile(imageInput: any) {
    const file: File = imageInput.files[0];
    const reader = new FileReader();
    reader.addEventListener('load', (event: any) => {
      this.selectedFile = new ImageSnippet(event.target.result, file);
      console.log(this.selectedFile.file);
    })
    reader.readAsDataURL(file);
                
   this.uploader.uploadAll();
  
}
 public uploader:FileUploader = new FileUploader({url: URL, itemAlias: 'newImage'});
  
 
}
Node Part
var express = require('express');
var app = express();
var multer = require('multer');
var path = require('path');
//Apply Path to diskStorage and File Name with extension
var storage = multer.diskStorage({
    destination: function (req, file, cb) {
      cb(null, '../src/assets/uploads/')
    },
    filename : function(req, file, callback) {
        console.log(file)
        callback(null, file.fieldname + '-' + Date.now() + path.extname(file.originalname))
    }
  });
   //Store in storage
    const upload = multer({
        storage: storage
    });
//For Single File upload
const singleUpload = upload.single('newImage');
var imageName='';
//upload file api to upload file
app.post('/uploadFile',function(req,res){
    
    singleUpload(req, res, function(err) {
       
        if (err) {
            return res.status(422).send({errors: [{title: 'File Upload Error', detail: err.message}] });
        }else{
            imageName =  req.file.filename;
            console.log(req.file.path);
            var imagePath = req.file.path;
            return res.send({success:true,  imageName});
        }
    })
});
 module.exports = app