ts-sn-utilities

A variant of RxJS exhaustMap that includes the trailing value emitted from the source observable while waiting for the inner observable to complete

Usage no npm install needed!

<script type="module">
  import tsSnUtilities from 'https://cdn.skypack.dev/ts-sn-utilities';
</script>

README

ts-sn-utilities

:star: Give a Star!

If you like or are using this project please give it a star here. Thanks!

✨ Features

  • Debouncer: Using the Debounce Operators, we wait until the user pauses typing before sending an HTTP Request. This will eliminates unnecessary HTTP requests.

☀️ License

🖥 Environment Support

  • Angular ^12.0.0 npm package

📦 Installation

NPM

npm install ts-sn-utilities --save

🔨 Usage

In your service write this code.

  getFilteredByCode(code: string): Observable<ApiResponse> {
    this.debouncerHelper.resetData();
    return this.debouncerHelper.debouncerOnly<string, ApiResponse>(1000, code, (request) => this.filterBy(request));
  }

🔗 Links

⌨️ Development

$ git clone git@github.com:ShadyNagy/ts-sn-utilities.git
$ cd ts-sn-utilities
$ npm install
$ cd ./projects/ts-sn-utilities
$ npm install
$ npm run build
$ npm run start

🤝 Contributing

PRs Welcome

We welcome all contributions. Please read our CONTRIBUTING.md first. You can submit any ideas as pull requests or as GitHub issues.

🎉 Users

We list some users here, if your company or product uses ts-sn-utilities, let us know here!