Skip to content

Commit

Permalink
fix(docs): Fix architecture diagram and questions (#4451)
Browse files Browse the repository at this point in the history
  • Loading branch information
Dr-Electron authored and miker83z committed Dec 20, 2024
1 parent a0972a6 commit 58b3faf
Show file tree
Hide file tree
Showing 7 changed files with 113 additions and 57 deletions.
2 changes: 1 addition & 1 deletion docs/content/developer/getting-started/getting-started.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ tags:
# Getting Started

IOTA Rebased introduces layer 1 Move smart contracts to the IOTA ecosystem. This valuable addition enhances IOTA by
offering programmability on layer1, complementing [IOTA EVM](../../about-iota/about-iota.mdx#iota-evm-and-shimmer-evm) on layer 2.
offering programmability on layer 1, complementing [IOTA EVM](../../about-iota/about-iota.mdx#iota-evm-and-shimmer-evm) on layer 2.

The guides in this section will guide you as you start your IOTA Rebased journey. We recommend that you start
by [setting up your development environment](iota-environment.mdx), and then move on
Expand Down
1 change: 0 additions & 1 deletion docs/content/developer/getting-started/local-network.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -274,5 +274,4 @@ pnpm add <PATH_TO_YOUR_REPO>/sdk/typescript

and the locally compiled version of `@iota/iota-sdk` package will be installed for your application.


<Quiz questions={questions} />
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.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
{
"questionText": "When first running the 'iota client' command, what happens if you press Enter without specifying a node URL?",
"answerOptions": [
{ "answerText": "It connects to the Devnet", "isCorrect": true },
{ "answerText": "It connects to the Testnet", "isCorrect": true },
{ "answerText": "It exits the program", "isCorrect": false },
{ "answerText": "It connects to the Mainnet", "isCorrect": false },
{ "answerText": "It shows an error message", "isCorrect": false }
Expand Down
Original file line number Diff line number Diff line change
@@ -1,29 +1,38 @@
[
{
"questionText": "What is the purpose of the `key` ability in a struct declaration in Move?",
"questionText": "What is the command to create a new IOTA Move package called 'my_first_package'?",
"answerOptions": [
{ "answerText": "It allows a struct to be stored and transferred.", "isCorrect": true },
{ "answerText": "It allows a struct to be copied.", "isCorrect": false },
{ "answerText": "It allows a struct to be dropped or discarded.", "isCorrect": false },
{ "answerText": "It allows a struct to be stored within structs with the `key` ability.", "isCorrect": false }
{ "answerText": "iota move new my_first_package", "isCorrect": true },
{ "answerText": "iota create package my_first_package", "isCorrect": false },
{ "answerText": "iota new package my_first_package", "isCorrect": false },
{ "answerText": "iota init my_first_package", "isCorrect": false }
]
},
{
"questionText": "Which ability allows a struct to be discarded in Move?",
"questionText": "What is the purpose of the Move.toml file in an IOTA Move package?",
"answerOptions": [
{ "answerText": "`copy`", "isCorrect": false },
{ "answerText": "`drop`", "isCorrect": true },
{ "answerText": "`key`", "isCorrect": false },
{ "answerText": "`store`", "isCorrect": false }
{ "answerText": "It is the package's manifest that describes the package and its dependencies.", "isCorrect": true },
{ "answerText": "It contains the source code of the modules.", "isCorrect": false },
{ "answerText": "It stores compiled bytecode.", "isCorrect": false },
{ "answerText": "It is used to manage version control.", "isCorrect": false }
]
},
{
"questionText": "How do you denote a comment in a `.move` file?",
"questionText": "In .toml files, which character is used to denote a comment?",
"answerOptions": [
{ "answerText": "Using double slashes `//`", "isCorrect": true },
{ "answerText": "Using `/* ... */`", "isCorrect": false },
{ "answerText": "Using `#`", "isCorrect": false },
{ "answerText": "Using `--`", "isCorrect": false }
{ "answerText": "Hash mark (#)", "isCorrect": true },
{ "answerText": "Double slash (//)", "isCorrect": false },
{ "answerText": "Semicolon (;)", "isCorrect": false },
{ "answerText": "Percent sign (%)", "isCorrect": false }
]
},
{
"questionText": "How can you resolve version conflicts in dependencies in the [dependencies] section?",
"answerOptions": [
{ "answerText": "By adding the 'override' field to the dependency", "isCorrect": true },
{ "answerText": "By removing the conflicting dependency", "isCorrect": false },
{ "answerText": "By renaming the dependency", "isCorrect": false },
{ "answerText": "By using a different package manager", "isCorrect": false }
]
}
]
122 changes: 85 additions & 37 deletions docs/site/static/json/developer/getting-started/local-network.json
Original file line number Diff line number Diff line change
@@ -1,38 +1,86 @@
[
{
"questionText": "What is the command to create a new IOTA Move package called 'my_first_package'?",
"answerOptions": [
{ "answerText": "iota move new my_first_package", "isCorrect": true },
{ "answerText": "iota create package my_first_package", "isCorrect": false },
{ "answerText": "iota new package my_first_package", "isCorrect": false },
{ "answerText": "iota init my_first_package", "isCorrect": false }
]
},
{
"questionText": "What is the purpose of the Move.toml file in an IOTA Move package?",
"answerOptions": [
{ "answerText": "It is the package's manifest that describes the package and its dependencies.", "isCorrect": true },
{ "answerText": "It contains the source code of the modules.", "isCorrect": false },
{ "answerText": "It stores compiled bytecode.", "isCorrect": false },
{ "answerText": "It is used to manage version control.", "isCorrect": false }
]
},
{
"questionText": "In .toml files, which character is used to denote a comment?",
"answerOptions": [
{ "answerText": "Hash mark (#)", "isCorrect": true },
{ "answerText": "Double slash (//)", "isCorrect": false },
{ "answerText": "Semicolon (;)", "isCorrect": false },
{ "answerText": "Percent sign (%)", "isCorrect": false }
]
},
{
"questionText": "How can you resolve version conflicts in dependencies in the [dependencies] section?",
"answerOptions": [
{ "answerText": "By adding the 'override' field to the dependency", "isCorrect": true },
{ "answerText": "By removing the conflicting dependency", "isCorrect": false },
{ "answerText": "By renaming the dependency", "isCorrect": false },
{ "answerText": "By using a different package manager", "isCorrect": false }
]
}
]
{
"questionText": "What command is used to start a local IOTA network with a test token faucet?",
"answerOptions": [
{
"answerText": "RUST_LOG=\"off,iota_node=info\" cargo run --bin iota iota",
"isCorrect": false
},
{
"answerText": "RUST_LOG=\"off,iota_node=info\" cargo run --bin iota start --force-regenesis --with-faucet",
"isCorrect": true
},
{
"answerText": "RUST_LOG=\"off,iota_node=info\" cargo run --bin iota client",
"isCorrect": false
},
{
"answerText": "cargo run --bin iota stop",
"isCorrect": false
}
]
},
{
"questionText": "Which flag should be used to persist data on the local network instead of using --force-regenesis?",
"answerOptions": [
{
"answerText": "--config-dir",
"isCorrect": true
},
{
"answerText": "--persist-data",
"isCorrect": false
},
{
"answerText": "--save-state",
"isCorrect": false
},
{
"answerText": "--data-dir",
"isCorrect": false
}
]
},
{
"questionText": "How can you retrieve the total transaction count from your local network using cURL?",
"answerOptions": [
{
"answerText": "curl --location --request GET 'http://127.0.0.1:9000' --header 'Content-Type: application/json' --data-raw '{\"jsonrpc\": \"2.0\", \"id\": 1, \"method\": \"iota_getTotalTransactionBlocks\", \"params\": []}'",
"isCorrect": false
},
{
"answerText": "curl --location --request POST 'http://127.0.0.1:9000' --header 'Content-Type: application/json' --data-raw '{\"jsonrpc\": \"2.0\", \"id\": 1, \"method\": \"iota_getTotalTransactionBlocks\", \"params\": []}'",
"isCorrect": true
},
{
"answerText": "curl --location --request POST 'http://127.0.0.1:9000' --header 'Content-Type: application/json' --data-raw '{\"jsonrpc\": \"2.0\", \"id\": 1, \"method\": \"iota_getTransactionCount\", \"params\": []}'",
"isCorrect": false
},
{
"answerText": "curl --location --request GET 'http://127.0.0.1:9000' --header 'Content-Type: application/json' --data-raw '{\"jsonrpc\": \"2.0\", \"id\": 1, \"method\": \"iota_getTransactionCount\", \"params\": []}'",
"isCorrect": false
}
]
},
{
"questionText": "What command is used to create a new environment for the IOTA Client CLI with an alias local and RPC URL http://127.0.0.1:9000?",
"answerOptions": [
{
"answerText": "iota client new-env --alias local --rpc http://127.0.0.1:9000",
"isCorrect": true
},
{
"answerText": "iota client create-env --alias local --rpc http://127.0.0.1:9000",
"isCorrect": false
},
{
"answerText": "iota client setup-env --alias local --rpc http://127.0.0.1:9000",
"isCorrect": false
},
{
"answerText": "iota client init-env --alias local --rpc http://127.0.0.1:9000",
"isCorrect": false
}
]
}
]

0 comments on commit 58b3faf

Please sign in to comment.