@anmetric/neta 1.1.2 → 1.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/package.json +1 -1
- package/types/index.d.ts +0 -1
package/README.md
CHANGED
|
@@ -552,7 +552,7 @@ Called before each retry attempt. Return:
|
|
|
552
552
|
- nothing — proceed normally
|
|
553
553
|
|
|
554
554
|
```js
|
|
555
|
-
import { stop } from "neta";
|
|
555
|
+
import { stop } from "@anmetric/neta";
|
|
556
556
|
|
|
557
557
|
neta.create({
|
|
558
558
|
hooks: {
|
|
@@ -573,7 +573,7 @@ neta.create({
|
|
|
573
573
|
Thrown for non-2xx responses (when `throwHttpErrors` is true).
|
|
574
574
|
|
|
575
575
|
```js
|
|
576
|
-
import { HTTPError } from "neta";
|
|
576
|
+
import { HTTPError } from "@anmetric/neta";
|
|
577
577
|
|
|
578
578
|
try {
|
|
579
579
|
await neta.get("https://api.example.com/missing");
|
|
@@ -591,7 +591,7 @@ try {
|
|
|
591
591
|
Thrown when a request exceeds the `timeout` or `totalTimeout`.
|
|
592
592
|
|
|
593
593
|
```js
|
|
594
|
-
import { TimeoutError } from "neta";
|
|
594
|
+
import { TimeoutError } from "@anmetric/neta";
|
|
595
595
|
|
|
596
596
|
try {
|
|
597
597
|
await neta.get(url, { timeout: 1000 });
|
|
@@ -607,7 +607,7 @@ try {
|
|
|
607
607
|
Thrown on network failures (DNS, connection refused, etc.).
|
|
608
608
|
|
|
609
609
|
```js
|
|
610
|
-
import { NetworkError } from "neta";
|
|
610
|
+
import { NetworkError } from "@anmetric/neta";
|
|
611
611
|
|
|
612
612
|
try {
|
|
613
613
|
await neta.get("https://nonexistent.invalid");
|
|
@@ -624,7 +624,7 @@ try {
|
|
|
624
624
|
Thrown when JSON response fails schema validation.
|
|
625
625
|
|
|
626
626
|
```js
|
|
627
|
-
import { SchemaValidationError } from "neta";
|
|
627
|
+
import { SchemaValidationError } from "@anmetric/neta";
|
|
628
628
|
|
|
629
629
|
try {
|
|
630
630
|
await neta.get(url).json(mySchema);
|
package/package.json
CHANGED