Phase 1: File Creation
1.1 - Locate the following:
src/api/blockchain/1Blockchain.txt
locate the Walltime link.
1.1 - Follow the hyperlink to read through the documentation and get an idea of the API usage.
1.2 - Create a file in the:
src/api/blockchain folder named BlockchainWalltime.js
1.3 - Add the following code to the file (this is just a placeholder:
const BlockchainWalltime = () => {
return (
);
};
export default BlockchainWalltime;
Phase 2: Routing
2.1 - Locate the following:
src/App.js
2.2 - Identify the correct place to insert (Try and group with others in its category:
<Route path="/Blockchain/BlockchainWalltime" element={<BlockchainWalltime />} />
!!NOTE!!
Make sure to type the component and select from the dropdown <BlockchainWalltime />
and then select from the dropdown so the file import is automatically populated
!!NOTE!!
2.3 - Locate the following:
src/api/blockchain/Blockchain1Dash.js
2.4 - Add the following component below the closing /> of the last Btn Routing:
<BtnRouting
btnName="Walltime"
navigateTo="BlockchainWalltime"
backgroundColor="#0077ba"
textColor="white"
/>
Phase 3: Content
3.1 - Locate the following (file you made):
src/api/blockchain/BlockchainWalltime.js
3.2 - Add the following code:
import { Box } from "@mui/material";
import BoxApiInfo from "../../core/main/BoxApiInfo";
import Endpoints from "../../core/main/Endpoints";
import BoxTest from "../../core/main/BoxTestCrud";
import NavBar from "../../core/main/navigation/NavBar";
const BlockchainWalltime = () => {
return (
<Box>
<NavBar link="/###" route2="/###" />
<Box>
<BoxTest />
<BoxApiInfo baseEndpoint="" />
<Endpoints header="GET" endpoint="/" />
<Endpoints
header="GET"
endpoint="/"
description="/"
/>
</Box>
</Box>
);
};
export default BlockchainWalltime;
3.3 - Add the base endpoint (found on the API site documentation)
3.4 - Add the endpoints (add extra components if there are more than 1)
3.5 - Test the functionality
4: Delete the link you used from the txt file (To keep track of what is left to add)
Have Fun :)