# ajax-notify

> Notifies when any ajax request performed in browser!

Latest version **2.0.2** (published 2020-09-20) · ISC license · 0 weekly downloads

## Install

```sh
npm install ajax-notify
pnpm add ajax-notify
yarn add ajax-notify
bun add ajax-notify
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.2 |
| Published | 2020-09-20 |
| First published | 2020-07-16 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 393.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | jatinparate |
| Maintainers | jatinparate |
| Keywords | Ajax Notify, Ajax, Notify, Fetch |

## Links

- npm: https://www.npmjs.com/package/ajax-notify
- Repository: https://github.com/jatin-parate-mlveda/ajax-notify
- Homepage: https://github.com/jatin-parate-mlveda/ajax-notify#readme
- Issues: https://github.com/jatin-parate-mlveda/ajax-notify/issues
- npm.io page: https://npm.io/package/ajax-notify

## Alternatives

- [launchdarkly-js-client-sdk](https://npm.io/package/launchdarkly-js-client-sdk.md) — 2.5M weekly downloads
- [@elastic/elasticsearch](https://npm.io/package/@elastic/elasticsearch.md) — 2.1M weekly downloads
- [@c8y/client](https://npm.io/package/@c8y/client.md) — 15.3K weekly downloads
- [@signaldb/maverickjs](https://npm.io/package/@signaldb/maverickjs.md) — 1.7K weekly downloads
- [@bbc/http-transport-cache](https://npm.io/package/@bbc/http-transport-cache.md) — 1.2K weekly downloads

## Recent versions

- 2.0.2 (latest) — 2020-09-20
- 2.0.1 — 2020-09-20
- 2.0.0 — 2020-09-20
- 1.0.3 — 2020-07-18
- 1.0.2 — 2020-07-16
- 1.0.1 — 2020-07-16
- 1.0.0 — 2020-07-16

## README

# **Ajax-Notify**

This package adds event listeners to 
XMLHttpRequest and fetch calls. Whenever
ajax is called using this two functions, 
provided callback function will be called.

## Api

This package exposes only one function as default.

    const { ajaxNotify } = require('ajax-notify');
    ajaxNotify(sutStringOrRegExp, (xhr, responseUrl) => {
        // xhr is undefined in case of fetch request
        console.log('request done', xhr, responseUrl);
    } )

Here ajaxNotify variable is a function.
It has two arguments.

- urlSubString: string or regular expression which will be included 
    or tested in request url
- callback: a function which will be executed when request url includes
    urlSubString. 

## NOTE:
- I haven't considered microsoft's ActiveX objects support because,
negligible number browsers use it.

---
_Source: https://npm.io/package/ajax-notify · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
