-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: move section content back to the .json file
- Loading branch information
1 parent
9055bba
commit 4b48a7e
Showing
10 changed files
with
104 additions
and
50 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,11 @@ | ||
import walletContent from '@/content/wallet.json' | ||
import type { getStaticProps } from '@/pages/wallet' | ||
import type { InferGetStaticPropsType } from 'next' | ||
import ChainsContext from '@/contexts/ChainsContext' | ||
import PageContent from '../common/PageContent' | ||
|
||
export const Wallet = () => <PageContent content={walletContent} path="wallet.json" /> | ||
export const Wallet = (props: InferGetStaticPropsType<typeof getStaticProps>) => ( | ||
<ChainsContext.Provider value={props.chainsData}> | ||
<PageContent content={walletContent} path="wallet.json" /> | ||
</ChainsContext.Provider> | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import type { InferGetStaticPropsType, NextPage } from 'next' | ||
import { Wallet } from '@/components/Wallet' | ||
import { loadChainsData } from '@/lib/loadChainsData' | ||
|
||
const WalletPage: NextPage<InferGetStaticPropsType<typeof getStaticProps>> = (props) => { | ||
return <Wallet {...props} /> | ||
} | ||
|
||
export async function getStaticProps() { | ||
const chainsData = await loadChainsData() | ||
|
||
return { | ||
props: { | ||
chainsData, | ||
}, | ||
} | ||
} | ||
|
||
export default WalletPage |