Skip to content

Commit

Permalink
lets pause for a second
Browse files Browse the repository at this point in the history
  • Loading branch information
amosmachora committed Oct 5, 2023
1 parent b6cc671 commit bdac6e6
Show file tree
Hide file tree
Showing 4 changed files with 346 additions and 20 deletions.
2 changes: 2 additions & 0 deletions hooks/useInitializeApp.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,13 @@ export const useInitializeApp = (
{
headers: {
Authorization: `Bearer ${encodedCredentials}`,
"Access-Control-Allow-Origin": "*",
},
}
);
return res.data;
} catch (err: any) {
console.error(err);
throw new Error(
`Error occurred with status code ${err.response?.status}, ${err.response?.statusText}`
);
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@
"version": "1.0.3",
"description": "A react library for interacting with Safaricom`s daraja APIs",
"main": "dist/index.js",
"module": "dist/index.mjs",
"module": "dist/index.cjs",
"types": "dist/index.d.ts",
"scripts": {
"test": "test",
"build": "tsup index.ts --format cjs,esm --dts --external axios",
"build": "tsup index.ts --format cjs,esm --dts --external axios --external react",
"lint": "tsc",
"release": "pnpm run build && changeset publish"
},
Expand Down
Loading

0 comments on commit bdac6e6

Please sign in to comment.