<100 subscribers
Truy cập link: https://remix.ethereum.org/
Tạo folder mới: Đặt tên gì tùy ae

Như bên dưới mình đã tạo thành công folder ffcrypto

Create new file

Đặt tên file tùy nhưng phải theo định dạng .sol, như bên dưới mình đặt là monad.sol

Paste toàn bộ code vào trong file mới tạo
// SPDX-License-Identifier: MIT
// Make sure the compiler version is below 0.8.24 since Cancun compiler is not supported just yet
pragma solidity >=0.8.0 <=0.8.24;
contract Gmonad {
string public greeting;
constructor(string memory _greeting) {
greeting = _greeting;
}
function setGreeting(string calldata _greeting) external {
greeting = _greeting;
}
}
Ấn close

Chọn vào Solidity compiler => Ở mục 0.8.26 chọn vào đó xong chọn tới ver 0.8.24+commit.e => Ấn Compile monad.sol

Chọn vào Deploy and run => Click vào Remix VM (Cancun) => Chọn vào Injected Provider - Metamask => Connect ví Metamask mạng Monad Testnet

Mục deploy điền: monad

Ấn deploy => Confirm lệnh trên metamask và đợi tầm 30s để lệnh xong

Truy cập mục Deployed Contracts => Ở mục setgreeting điền monad hello

Sau đó ấn setGreeting và confirm trên Metamask

Truy cập link: https://remix.ethereum.org/
Tạo folder mới: Đặt tên gì tùy ae

Như bên dưới mình đã tạo thành công folder ffcrypto

Create new file

Đặt tên file tùy nhưng phải theo định dạng .sol, như bên dưới mình đặt là monad.sol

Paste toàn bộ code vào trong file mới tạo
// SPDX-License-Identifier: MIT
// Make sure the compiler version is below 0.8.24 since Cancun compiler is not supported just yet
pragma solidity >=0.8.0 <=0.8.24;
contract Gmonad {
string public greeting;
constructor(string memory _greeting) {
greeting = _greeting;
}
function setGreeting(string calldata _greeting) external {
greeting = _greeting;
}
}
Ấn close

Chọn vào Solidity compiler => Ở mục 0.8.26 chọn vào đó xong chọn tới ver 0.8.24+commit.e => Ấn Compile monad.sol

Chọn vào Deploy and run => Click vào Remix VM (Cancun) => Chọn vào Injected Provider - Metamask => Connect ví Metamask mạng Monad Testnet

Mục deploy điền: monad

Ấn deploy => Confirm lệnh trên metamask và đợi tầm 30s để lệnh xong

Truy cập mục Deployed Contracts => Ở mục setgreeting điền monad hello

Sau đó ấn setGreeting và confirm trên Metamask

Share Dialog
Share Dialog
No comments yet