Skip to content

Footer: Compile, Create, and Commit a list of footer links into a static JSON object #3475

Open
@micahchiang

Description

@micahchiang

Description

We recently wrapped up some discovery around how the current footer is built. We haven't yet decided on how we'll build the new footer, though it'll likely be either option 2, or 3, or a hybrid of both, as outlined in the aforementioned discovery work.

Regardless of what we decide, it's been confirmed that footer link data does not need to live in Drupal, and by removing it from there we'd be able to get rid of an entire build step that takes a considerable amount of time. Furthermore, doing so would eliminate the risk of someone adding ill-formed link data to Drupal which has historically caused either the header or footer to break.

Given the above, a next step for building a footer web component is to compile a list of existing links, create a static JSON object of those links, and commit that JSON object to github, either in the component-library repo or in some other location if we feel it's right to do so. Eventually our footer web component will consume this JSON to render links.

Considerations

  • create-header-footer.js and footer-links.json contain information on how footer links are currently structured. We should take a look at this and determine if the structure is fine or we have an opportunity to refactor into something more succinct.
  • We can probably get all the information we need for existing links on the headerFooter window object by typing window.VetsGov.headerFooter in the dev console.
  • We should document as we go. Once a decision is made on how we're going to structure our JSON, we should add a decision doc to confluence that details the thought process behind the decision. Eventually it may be worthwhile to create a json schema for footer entries so we can validate new additions in a build step or github workflow.

Tasks

  • Create a JSON object comprised of our current footer data.
  • Find a place to commit it to github, either in component-library or somewhere else if it makes sense
  • Write a brief decision doc in confluence for link structure

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    DST-engineeringIssues that require work from Design System Team engineersva-footer

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions