Skip to content

Commit e009c33

Browse files
committed
chore: style linting lesson 3
1 parent bb28fe9 commit e009c33

File tree

7 files changed

+50
-51
lines changed

7 files changed

+50
-51
lines changed

src/pages/lessons/fundamentals/open_zeppelin.mdx

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
2-
title: Open Zeppelin
3-
description: Overview of Open Zeppelin Contracts.
2+
title: OpenZeppelin
3+
description: Overview of OpenZeppelin Contracts.
44
icons: ["openzeppelin"]
55
author: ["piablo", "7i7o"]
66
---
@@ -9,10 +9,10 @@ import { LessonHeader } from "../../../components/mdx/LessonHeader";
99
import Layout from "../../../components/Layout";
1010

1111
<Layout
12-
title="Open Zeppelin"
13-
description="Overview of Open Zeppelin Contracts."
12+
title="OpenZeppelin"
13+
description="Overview of OpenZeppelin Contracts."
1414
>
15-
<LessonHeader title="Open Zeppelin Smart Contract Concepts" />
15+
<LessonHeader title="OpenZeppelin Smart Contract Concepts" />
1616

1717
We are going to stand on the shoulder of giants and leverage the power of open
1818
source to create our project in a simpler way, while not losing focus on
@@ -24,13 +24,13 @@ a lot of _hoping for the best_ that they wouldn’t get hacked. Since the space
2424
was new, there was a real need for developers who would specialise in rigorously
2525
auditing contracts, since they were holding a lot of value.
2626

27-
The Open Zeppelin team, slowly but surely, began to fill that gap creating a
27+
The OpenZeppelin team, slowly but surely, began to fill that gap creating a
2828
library of contracts that _have_ been rigorously audited and proven to be safe
2929
and robust by all the OG protocols of the Ethereum Network, and many more.
3030

3131
**So what are they and how do they help us?**
3232

33-
By (re)using and these Open Zeppelin libraries, we devs can reduce the amount of
33+
By (re)using and these OpenZeppelin libraries, we devs can reduce the amount of
3434
code we write, and that's a good thing. By reducing the _surface area for attack
3535
vectors_ our contracts are much less likely to be hacked. Since they are often
3636
used as an ecosystem standard, they allow for much easier collaboration among
@@ -44,12 +44,11 @@ at, the field of possibilities opens up exponentially. Exciting times to be
4444
developing!
4545

4646
To make development easier still and take advantage of their offerings, there is
47-
an OpenZeppeilin Wizard which lets you choose your own style of modularity,
47+
an OpenZeppelin Contracts Wizard which lets you choose your own style of modularity,
4848
whether that is to mint, burn, vote, give a range of access permissions, you
49-
name it, it’s there! Note the import of ERC721 in the one below…..I’ll stop
50-
nattering now! See for yourself:
49+
name it, it’s there! Note the import of `ERC721` in the one below.
5150

52-
![Open Zeppelin](/assets/lessons/open_zeppelin/ERC721.Ownable.png)
51+
![OpenZeppelin](/assets/lessons/open_zeppelin/ERC721.Ownable.png)
5352

5453
So when we write a new contract, and we need to **_inherit_** the tried and
5554
tested qualities or characteristics, we simply **_import_** those contracts into

src/pages/lessons/projects/3.mdx

Lines changed: 21 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -91,14 +91,14 @@ tiered NFTs and uncover the unique superpowers they possess. By the end of this
9191
tutorial, you will have gained a wealth of knowledge and accomplished the
9292
following steps:
9393

94-
- Setting up the development environment
95-
- Writing and deploying a Solidity smart contract
96-
- Creating tiered NFTs with varying levels of rarity and attributes
97-
- Write scripts for deployment
98-
- Exploring additional functionalities and possibilities with tiered NFTs ... in
94+
- Set up a development environment
95+
- Write and deploy a Solidity smart contract
96+
- Create tiered NFTs with varying levels of rarity and attributes
97+
- Write a script for deployment
98+
- Explore additional functionalities and possibilities with tiered NFTs... in
9999
the smart contract!
100100
- Securely manage sensitive environment variables
101-
- Showcasing your tiered NFTs on a public marketplace
101+
- Showcase your tiered NFTs on a public marketplace
102102

103103
### Developer tooling
104104

@@ -111,7 +111,7 @@ These tools include:
111111
- optional decentralized storage accounts
112112
- a web3 wallet for testing
113113
- some test MATIC
114-
- an API key from an RPC provider.
114+
- an API key from an RPC provider
115115

116116
We will guide you through each step, ensuring a fun and comprehensive learning
117117
experience. Let's get started on this exciting journey into the world of tiered
@@ -126,8 +126,8 @@ as our package manager, we'll create a Hardhat project and remove the default
126126
files we don't need.
127127

128128
Let’s first open a console and `cd` into our `d_d_academy` folder, or create it
129-
first if you haven't already. Then create a folder for our TierNFT project and
130-
make sure to `cd` into it too:
129+
first if you haven't already. Then create a folder for our TierNFT project, then
130+
`cd` into it:
131131

132132
```bash
133133
## (OPTIONAL) create a folder for our D_D Academy projects
@@ -149,14 +149,14 @@ npx hardhat
149149
```
150150

151151
<Callout emoji="💡" size="md" variant="info">
152-
The `--save-dev` flag used in the last command, lets the project know it's a
153-
development dependency (not needed in production). You can view what
152+
The `--save-dev` flag used in the last command lets the project know it's a
153+
development dependency, i.e., not needed in production. You can view what
154154
dependencies are needed in the `package.json` file in the root of the project.
155155
</Callout>
156156

157157
Choose `Create a Javascript project` and hardhat will create an example project
158-
for us. It will give us 3 prompts for options. Choosing the defaults is ok for
159-
us. Here's what mine asked me:
158+
for us. It will give us 3 prompts for options. The default options are okay for
159+
our purposes. Here are the prompts at the time of writing:
160160

161161
```less
162162
✔ What do you want to do? · Create a JavaScript project
@@ -184,6 +184,7 @@ npm install --save-dev hardhat @nomicfoundation/hardhat-toolbox
184184
```
185185
186186
</Callout>
187+
187188
In a Hardhat project, some of the default folders are:
188189
189190
- `contracts/` where the source files for your contracts should be.
@@ -205,11 +206,11 @@ We now need to add our last dependency. The OpenZeppelin contracts:
205206
npm install @openzeppelin/contracts
206207
```
207208
208-
<Callout emoji="💡" size="md" variant="info">
209-
Open Zeppelin developed a lot of standard contracts that are super powerful,
210-
widely used and fully tested and audited.
211-
</Callout>
212-
<SideDrawer buttonText="More on Open Zeppelin">
209+
OpenZeppelin is best known for implementing freely available contracts for
210+
various standards. They are powerful and widely used building blocks for Solidity
211+
developers, and come fully tested and audited.
212+
213+
<SideDrawer buttonText="More on OpenZeppelin">
213214
<OpenZeppelin />
214215
</SideDrawer>
215216
@@ -440,7 +441,7 @@ contract TierNFT is ERC721 {
440441
441442
### Create tokenURI function
442443
443-
When we inherited Open Zeppelin's ERC721, it gave us a function for `tokenURI` where we can store an image, a video, or much more. With the help of this ERC721 contract we have the ability to define **a base path** for creating a
444+
When we inherited OpenZeppelin's ERC721, it gave us a function for `tokenURI` where we can store an image, a video, or much more. With the help of this ERC721 contract we have the ability to define **a base path** for creating a
444445
unique URI which adds the token ID to the end of it.
445446
446447
```solidity
@@ -755,7 +756,7 @@ We need to find a way to actually withdraw any funds our contract generates, oth
755756
import "@openzeppelin/contracts/access/Ownable.sol";
756757
````
757758
758-
And inherit `Ownable` from the Open Zeppelin contract into our own.
759+
And inherit `Ownable` from the OpenZeppelin contract into our own.
759760
760761
```solidity
761762
// Modify the contract definition, by adding 'Ownable' at the end of the line:

src/utils/questions/lesson-3/1-intro/Q1.json

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,16 @@
11
{
2-
"question": "Which steps are needed to code a basic smart contract for deployment?",
2+
"question": "Which steps are needed to write a basic smart contract?",
33
"options": [
44
{
5-
"answer": "Create a smart contract using a code editor."
6-
},
7-
{
8-
"answer": "Create a project template."
5+
"answer": "Use a code editor to write a smart contract",
6+
"correct": true
97
},
108
{
11-
"answer": "Install dependencies."
9+
"answer": "Create a project template",
10+
"correct": true
1211
},
1312
{
14-
"answer": "All of the above.",
13+
"answer": "Install dependencies",
1514
"correct": true
1615
}
1716
]

src/utils/questions/lesson-3/1-intro/Q2.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,17 @@
22
"question": "What does the term 'gas' refer to in the context of Ethereum?",
33
"options": [
44
{
5-
"answer": "Digital currency used for transactions."
5+
"answer": "Digital currency used for transactions"
66
},
77
{
8-
"answer": "Unit of measure for computational effort.",
8+
"answer": "Unit of measure for computational effort",
99
"correct": true
1010
},
1111
{
12-
"answer": "A poisonous fossil fuel."
12+
"answer": "A poisonous fossil fuel"
1313
},
1414
{
15-
"answer": "Encryption algorithm used in smart contracts."
15+
"answer": "Encryption algorithm used in smart contracts"
1616
}
1717
]
1818
}

src/utils/questions/lesson-3/1-intro/Q3.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22
"question": "Which of the following describes a URI?",
33
"options": [
44
{
5-
"answer": "A Uniform Resource Identifier.",
5+
"answer": "A Uniform Resource Identifier",
66
"correct": true
77
},
88
{
9-
"answer": "A web address that points to content and information.",
9+
"answer": "A web address that points to content and information",
1010
"correct": true
1111
}
1212
]

src/utils/questions/lesson-3/1-intro/Q4.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,17 +2,17 @@
22
"question": "Which of the following go into `hardhat.config.js` in an NFT project?",
33
"options": [
44
{
5-
"answer": "NFT_NAME."
5+
"answer": "NFT_NAME"
66
},
77
{
8-
"answer": "RPC_API_KEY.",
8+
"answer": "RPC_API_KEY",
99
"correct": true
1010
},
1111
{
12-
"answer": "tokenURI."
12+
"answer": "tokenURI"
1313
},
1414
{
15-
"answer": "All of the above."
15+
"answer": "All of the above"
1616
}
1717
]
1818
}

src/utils/questions/lesson-3/1-intro/Q5.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
2-
"question": "Which answer is 'truthier'?",
2+
"question": "Which answer is true of NFT data storage?",
33
"options": [
44
{
5-
"answer": "We need a `.json` file to store our NFT data."
5+
"answer": "NFT data must be stored in a `.json` file."
66
},
77
{
8-
"answer": "We can store NFT data in a smart contract.",
8+
"answer": "NFT data can be stored in a smart contract.",
99
"correct": true
1010
}
1111
]

0 commit comments

Comments
 (0)