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

Connect GraphQL to magazine related blocks #136

Open
4 tasks
santi-homps opened this issue Dec 2, 2024 · 0 comments
Open
4 tasks

Connect GraphQL to magazine related blocks #136

santi-homps opened this issue Dec 2, 2024 · 0 comments

Comments

@santi-homps
Copy link
Collaborator

santi-homps commented Dec 2, 2024

Context/Description

Connect GraphQL Endpoint to all magazine related blocks

Create a function with the query needed to retrieve all the articles's information.
Configure this function in order to allow optional parameters that query the DB and retrieve only the necessary list of articles.
Make all blocks that need articles work with this function.
Replace fetchMagazineArticles() function in magazine.service.js file
Delete unused logic from the blocks. FE: sorting or trimming of articles

Blocks affected:

  • related-articles
  • v2-article-cards
  • v2-stories-carousel

ALSO:
magazine-articles block has this query already applied but should be moved to the magazine.service.js file so that all the logic behind this call is unified.

Acceptance Criteria

  • All blocks that use the magazine article list get them from the new DB endpoint and not from sharepoint's magazine-articles.xslx file
  • The blocks that don't need the whole list of articles retrieve only the ones needed by passing different params (fe: limit, truck, etc)
  • The function is available for all future blocks in the file magazine.service.js
  • All affected blocks work as before but pulling from the new endpoint
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

When branches are created from issues, their pull requests are automatically linked.

4 participants