Closed AMIRKHANEF closed 3 days ago
The changes in this pull request focus on the Governance
component within the index.tsx
file, where the useManifest
hook is introduced to replace the previous method of fetching the manifest from a JSON file. This transition simplifies the data flow by removing the fetchJson
function and its associated useEffect
. The manifest
state is now directly initialized using the useManifest
hook, and the rendering logic has been adjusted accordingly. Additionally, a minor formatting change was made in the useManifest
function declaration.
File Path | Change Summary |
---|---|
packages/extension-polkagate/src/fullscreen/governance/index.tsx |
- Updated import to include useManifest hook.- Removed fetchJson function and useEffect for manifest fetching.- Initialized manifest state using useManifest() .- Adjusted rendering logic to use manifest for displaying application version and governance support. |
packages/extension-polkagate/src/hooks/useManifest.ts |
- Minor formatting change in the function declaration of useManifest . |
SimpleModalTitle
component, which is relevant to the main PR as it also involves changes in the governance components, specifically in how titles are rendered in modals.change requested
In the land of governance, changes unfold,
A hook for the manifest, a story retold.
No more fetching, just a simple call,
The version displayed, we’ll share with all!
With each little tweak, our code grows bright,
Hopping along, we’ll code through the night! 🐇✨
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
close: #1649
Summary by CodeRabbit
New Features
useManifest
, to streamline the retrieval of application manifest data.Bug Fixes
Refactor