Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Document the locations on GET {component}/usage

Open Beginner friendly
#265 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
79/100
Issue type
Documentation
Clarity
Clearly specified
Activity status
Active
Domain
documentation

Research direction

Read the API documentation under content/4.api/ and find the components section for GET {component}/usage. Document the role-specific locations field, location and rendering details, ordering, caps, exact counts, and private, no-store caching behavior from the issue. Done when the endpoint docs cover each listed behavior and distinguish the admin response from responses without locations.

Written by the indexing model from the issue text.

Description

The bundle's GET {component}/usage now lists where a component is used, for admins (components-web-app/api-components-bundle#531, PR components-web-app/api-components-bundle#535). The module uses it for the "Shared · N places" badge and its list of places.

Please document, in the API section on components (content/4.api/):

  • The response keeps positionCount, pageDataCount and total, and adds locations for ROLE_ADMIN only. Anyone else who may read the component still gets the counts, without the locations key.
  • Each location is one counted use: componentPosition (a position IRI) or pageData + property (a page data property holding the component). A dynamic position whose fallback is the component is listed with pageDataProperty set. total - locations.length is the number of uses not listed.
  • layout is {iri, reference} for a use in a layout (directly or through components in the layout); renderedOn is then empty for the layout, since every page using it shows the component.
  • renderedOn lists each page or page data the use renders on: {iri, title, routePath}, where routePath is the route's own path without the import prefix, or null when unrouted. A template position renders on the template and every page data using it; a position inside a component renders wherever that component is placed, up the chain.
  • Order: layout uses first, then routed uses by route path, then unrouted uses by title. renderedOn is ordered by route path, then unrouted by title.
  • Caps: 50 locations and 20 renderedOn per location; total and renderedOnCount are exact.
  • The response is private, no-store: a shared cache never stores it, since nothing purges it when a placement changes.
Dominant language
TypeScript
Stars
0
Forks
0
Avg merge
1h 20m
Merged PRs (30d)
1

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from components-web-app/docs

All issues in components-web-app/docs

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.