Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(client): support headers in client #2611

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

javadkh2
Copy link
Collaborator

@javadkh2 javadkh2 commented Oct 24, 2024

add support for headers to client

Related Issue/Asana ticket: _

this will let hostUrlGenerator returns { hostUrl , requestInit} object, then the headers will be added to the fetch request

const client = createClient(({ networkId, chainId }) => ({
  hostUrl: 'url',
  requestInit:{ header: myCustomHeaders },
}));

Also now all functions accept requestInit object

const abortController = new AbortController()
const result = client.pollStatus(keys, { signal: abortController.signal })

Test scenarios

  • description of the (manually) executed test scenarios

Reminders (if applicable)

  • I ran pnpm install and pnpm test in the root of the monorepo
    (optionally with --filter=...package... to exclude non-affected
    projects)
  • I ran pnpm changeset in the root of the monorepo
  • Test coverage has not decreased
  • Docs have been updated to reflect changes in PR (don't forget
    docs.kadena.io)

Copy link

vercel bot commented Oct 24, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
dev-wallet ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 20, 2024 0:58am
explorer ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 20, 2024 0:58am
marmalade-marketplace ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 20, 2024 0:58am
proof-of-us ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 20, 2024 0:58am
rwa-demo ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 20, 2024 0:58am
tools ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 20, 2024 0:58am
2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
alpha-docs ⬜️ Ignored (Inspect) Visit Preview 💬 Add feedback Nov 20, 2024 0:58am
kode-ui ⬜️ Ignored (Inspect) Visit Preview Nov 20, 2024 0:58am

Copy link

changeset-bot bot commented Oct 24, 2024

🦋 Changeset detected

Latest commit: 24bf6ec

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 16 packages
Name Type
@kadena/chainweb-node-client Minor
@kadena/client Minor
@kadena/dev-wallet Patch
@kadena/graph Patch
@kadena/client-examples Patch
@kadena/client-utils Patch
@kadena/dev-wallet-example Patch
@kadena/marmalade-marketplace Patch
@kadena/proof-of-us Patch
@kadena/spirekey-example Patch
@kadena/kadena-cli Patch
@kadena/pactjs-cli Minor
@kadena/dev-wallet-desktop Patch
@kadena/explorer Patch
@kadena/graph-client Patch
@kadena/pactjs-generator Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants