ipld-explorer-components icon indicating copy to clipboard operation
ipld-explorer-components copied to clipboard

feat: StartExploringPage should accept a config for ExploreLinks

Open SgtPooki opened this issue 2 years ago • 4 comments

We should allow overriding default explore links in this component, instead of always defaulting to:

https://github.com/ipfs/ipld-explorer-components/blob/edd95a4bd4c12fb55f0815ebbe18847f65f84823/src/components/StartExploringPage.jsx#L35-L77

We should allow consumers to pass their desired links in the format of:

const explorePageLinks = [
  { name: 'Project Apollo Archives', cid: 'QmSnuWmxptJZdLJpKRarxBMS2Ju2oANVrgbr2xWbie9b2D' type: 'dag-pb', },
  { name: 'XKCD Archives', cid: 'QmdmQXB2mzChmMeKY47C43LxUdg1NDJ5MWcKMKxDu7RgQm', type: 'dag-pb', },
  // ...
]
<StartExploringPage
  links={explorePageLinks}
/>

Known consumers that will need to update:

  • devPage.jsx at https://github.com/ipfs/ipld-explorer-components/blob/master/dev/devPage.jsx
  • explore.ipld.io at https://github.com/ipld/explore.ipld.io/blob/964e313eca3f03d330b4f9fc817166431d5ba171/src/bundles/routes.js#L6-L7
  • webui at https://github.com/ipfs/ipfs-webui/blob/7a3388e3d17560d3e376e57361dd78b8c7fdf8e9/src/bundles/routes.js#L14
  • webui at https://github.com/ipfs/ipfs-webui/blob/7a3388e3d17560d3e376e57361dd78b8c7fdf8e9/src/explore/StartExploringContainer.js#L10

SgtPooki avatar Dec 01 '23 19:12 SgtPooki

I can do this.. its pretty straightforward

KirtanSoni avatar Dec 27 '23 19:12 KirtanSoni

@KirtanSoni that would be amazing =)

SgtPooki avatar Feb 01 '24 18:02 SgtPooki

Can I work on this if this is available ?

ravishxt avatar May 11 '24 07:05 ravishxt

@ravishxt please do

SgtPooki avatar May 14 '24 18:05 SgtPooki

this is done

SgtPooki avatar Sep 20 '24 14:09 SgtPooki