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

Hooks & docs for langauge and hooks #450

Merged
merged 10 commits into from
Feb 20, 2024
Merged

Hooks & docs for langauge and hooks #450

merged 10 commits into from
Feb 20, 2024

Conversation

fayeed
Copy link
Member

@fayeed fayeed commented Feb 19, 2024

No description provided.

@fayeed fayeed marked this pull request as ready for review February 19, 2024 13:45
Copy link
Member

@lucksus lucksus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not really happy with the hooks docs.

  1. Should be code comments so that it gets integrated into our reference and shows in IDEs
  2. The description don't really say much about the hook but just repeat the concept of hooks and have wrong expansions of the ADAM abbreviation (I started fixing this in the change suggestions but stopped at some point).

ad4m-hooks/helpers/src/cache.ts Outdated Show resolved Hide resolved
ad4m-hooks/react/src/useSubject.tsx Outdated Show resolved Hide resolved
ad4m-hooks/react/src/useSubject.tsx Outdated Show resolved Hide resolved
ad4m-hooks/react/src/useSubjects.tsx Outdated Show resolved Hide resolved
ad4m-hooks/react/src/useSubjects.tsx Outdated Show resolved Hide resolved
ad4m-hooks/vue/src/useClient.ts Outdated Show resolved Hide resolved
docs/pages/hooks.mdx Outdated Show resolved Hide resolved
docs/pages/hooks.mdx Outdated Show resolved Hide resolved

## useClient

The `useClient` hook is a custom React hook designed to manage state related to fetching and caching an AD4M (Agent-centric Decentralized Data Management) client in React applications. It provides an easy-to-use interface for interacting with the AD4M client, abstracting away the complexities of data fetching, caching, and error handling.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
The `useClient` hook is a custom React hook designed to manage state related to fetching and caching an AD4M (Agent-centric Decentralized Data Management) client in React applications. It provides an easy-to-use interface for interacting with the AD4M client, abstracting away the complexities of data fetching, caching, and error handling.
The `useClient` hook provides access to the underlying `Ad4mClient`.

docs/pages/languages.mdx Outdated Show resolved Hide resolved
Copy link
Member

@lucksus lucksus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, let's move over / add docs as code comments for the reference in a later PR.

@lucksus lucksus merged commit c5a2a20 into dev Feb 20, 2024
0 of 3 checks passed
@lucksus lucksus mentioned this pull request Mar 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants