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

HOWTO: Recipes for working with GraphQL or normalization [cache, normalizers, repositories] #463

Open
SuperOleg39 opened this issue Feb 17, 2022 · 4 comments
Assignees

Comments

@SuperOleg39
Copy link

At the moment, the documentation does not answer the question of which layer might be responsible for distributing data from the API to the different entities

@azinit
Copy link
Member

azinit commented Feb 17, 2022

@SuperOleg39 thanks for issue!

Could you please specify some details?

"which layer might be responsible for distributing data from the API to the different entities"

  1. For GraphQL - there is usually responsible for-cache client (e.g. ApolloClient)
    Thus any API-request will be distributed to "entities" automatically with this cache-client, won't it?
    And the question is, what exactly would you like to see in the documentation with GraphQL?

  2. For normalization in general
    Would you like to see dataflow recommendations like these?

    • "How to organize data normalization in FSD layers?"
    • "Where to store normalizers of entities and how to bind them with API requests?"

@azinit azinit changed the title Recipes for working with GraphQL or normalization HOWTO: Recipes for working with GraphQL or normalization Feb 17, 2022
@SuperOleg39
Copy link
Author

Good point for GraphQL, i did not think about the fact that the results of the query do not need to be stored somewhere else.

About normalization, both of recommendations sounds very useful!

@azinit
Copy link
Member

azinit commented Feb 17, 2022

Good point for GraphQL, i did not think about the fact that the results of the query do not need to be stored somewhere else.

Yeah, we'll try to describe it in documentation, but at least we have representive GraphQL example
https://github.com/ani-team/github-client/tree/workshop/feature-sliced-next

About normalization, both of recommendations sounds very useful!

Good! At the moment @RinAkaia is writing article about "Entities normalization"
And we will do everything possible to make this article appear sooner

But while waiting for the article, you can look up these materials:

@azinit azinit changed the title HOWTO: Recipes for working with GraphQL or normalization HOWTO: Recipes for working with GraphQL or normalization [cache, normalizers, repositories] Feb 17, 2022
@SuperOleg39
Copy link
Author

Thanks you very much!
Will be waiting for a new article)

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

No branches or pull requests

3 participants