0.0.3 • Published 5 years ago

rxjs-x v0.0.3

Weekly downloads
7
License
MIT
Repository
github
Last release
5 years ago

RxjsX

Use decorator to auto free Subscription when component destroy

Example

import { AutoFree } from 'rxjs-x';

@AutoFree()
@Component({
  selector: 'app-test',
  template: ``,
})
export class TestComponent implements OnDestroy {
  interval: Subscription = interval(2000).pipe().subscribe((num) => {
    console.log('subscribe: ', num);
  });

  ngOnDestroy() {
    console.log(this.interval);
  }
}
0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago