- Github account would be nice (not necessary)
- Metamask link for installation (advised not essential)
- Test Ether https://goerli-faucet.mudit.blog/ (not necessary)
- Make a new workspace with the default template
- Change the name of the workspace
- Change the theme - by going to the Settings tab
- And check what else is in settings
- You will probably be adding a github key later
- Go to the Plugin Manager
- Activate Learneth (although you could do this on the hometab)
- Check the tutorials Solidity Beginner Course, Soldity ERC20 Token Course, Soldity NFT Course, and the NFT Auction Contract course.
- Go back to the File Explorer and choose 2_owner.sol
- Compile it in the Solidity Compiler
- Then compile it again with the clue mentioned here: https://twitter.com/EthereumRemix/status/1511901727389147136
- Click the follow button in Twitter (only if you like)
- In the top of the Solidity Compiler, click the
>
symbol and then click the link to get to the documentation of this plugin. - Open a new tab and go to:
- https://medium.com/remix-ide to see our articles
- Our docs are located at: https://remix-ide.readthedocs.io
- Go to the Deploy & Run Module
- Deploy 2_Owner.sol to remix vm
- Interact with the changeOwner function - in 2_Owner.sol
- Hint: you need to input an account address that is not the address of the 1st account in the ACCOUNT select box. If you switch to a different account to copy, remember to switch back to the original account.
- Start a debugging session from the terminal
- Find out what the solidity state & local variables are at different points by dragging the slider or stepping through the transaction.
- Switch back to the Deploy & Run Module. Then deploy to another testnet (ganache, hardhat, or a public test chain with Metamask)
- Check the use of console.log in 2_Owner.sol
- Edit the message on line 33.
- Compile and deploy the contract.
- Find your message in the terminal.
- Try putting a console.log in the changeOwner function.
- Compile and Deploy the contract.
- Open up the deployed instance and find the changeOwner function.
- Change the account and copy the new account.
- Switch back to the original account.
- Paste the account address that you copied into changeOwner's parameter newOwner.
- Click the changeOwner button.
- Why did you need to change back to the original account to run this function?
- Find the console.log message you put in this function.
- Make a function
changeOwner
payable: - Add the word payable after the word public on line 42. - - - Compile the contract and deploy it to the Remix VM.
- Send 4 ETH to the contract (using our not so intuitive UI)
- Check gas usage of the function - see gas line in the editor
- In the deployed instance, see how much value has been sent to the contract.
- In the File Explorer, click the clone icon on the row of Workspace icons.
- and use this repo - or any other you like:
https://github.com/Aniket-Engg/solidity-school.git
- Go to https://wizard.openzeppelin.com and add some features (or not) and then click on the Open in Remix button.
- This will open Remix in a new tab and the workspace will be code-sample.
- Compile it.
- Then in the Editor, hover over the word onlyOwner.
- See the window that pops up. (The file must be compiled for this to pop up).
- Right click on the onlyOwner and choose Go to Definition.