FE/Angular

[ ANGULAR ] 새로운 subscribe 패턴

HEON.D 2023. 6. 3. 16:15
    const subscription = this.apiService.post(params)
    .pipe(first()).subscribe({
      next: (res) => {
      },
      error: (error) => {
      },
      complete: () => {
        this.getData();
        this.commonService.loadFinish();
      }
    });