diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index 72aa11d..5fcb7d5 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -47,7 +47,7 @@ body: id: terms attributes: label: Code of Conduct - description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/zkSync-Community-Hub/community-code/blob/main/CODE_OF_CONDUCT.md). + description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/ZKsync-Community-Hub/community-code/blob/main/CODE_OF_CONDUCT.md). options: - label: I agree to follow this project's Code of Conduct required: true diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index e094d73..fcdf707 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -1,5 +1,5 @@ blank_issues_enabled: true contact_links: - name: zksync-developers Discussion - url: https://github.com/zkSync-Community-Hub/zkync-developers/discussions + url: https://github.com/ZKsync-Community-Hub/zkync-developers/discussions about: If you have any questions or need help beyond this project, please visit our Discussions page for zksync developers. diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml index 10d15a2..5a3d901 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.yml +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -25,7 +25,7 @@ body: id: terms attributes: label: Code of Conduct - description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/zkSync-Community-Hub/community-code/blob/main/CODE_OF_CONDUCT.md). + description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/ZKsync-Community-Hub/community-code/blob/main/CODE_OF_CONDUCT.md). options: - label: I agree to follow this project's Code of Conduct required: true diff --git a/.github/ISSUE_TEMPLATE/new_guide_request.yml b/.github/ISSUE_TEMPLATE/new_guide_request.yml index 51ba51b..5adae79 100644 --- a/.github/ISSUE_TEMPLATE/new_guide_request.yml +++ b/.github/ISSUE_TEMPLATE/new_guide_request.yml @@ -19,7 +19,7 @@ body: id: terms attributes: label: Code of Conduct - description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/zkSync-Community-Hub/community-code/blob/main/CODE_OF_CONDUCT.md). + description: By submitting this issue, you agree to follow our [Code of Conduct](https://github.com/ZKsync-Community-Hub/community-code/blob/main/CODE_OF_CONDUCT.md). options: - label: I agree to follow this project's Code of Conduct required: true diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index 977618e..87564a6 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -1,11 +1,11 @@ diff --git a/.lintstagedrc.yml b/.lintstagedrc.yml index 073a606..62c9d45 100644 --- a/.lintstagedrc.yml +++ b/.lintstagedrc.yml @@ -2,7 +2,7 @@ - prettier --list-different - eslint '*.md': - - cspell check + - cspell lint --file - markdownlint-cli2 '*.{json,yml}': - prettier --list-different diff --git a/.vscode/settings.json b/.vscode/settings.json index 32a3f97..caba456 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -19,5 +19,13 @@ }, "editor.tabCompletion": "onlySnippets" }, - "eslint.experimental.useFlatConfig": true + "eslint.experimental.useFlatConfig": true, + "workbench.colorCustomizations": { + "statusBar.background": "#8257a6", + "statusBar.foreground": "#e7e7e7", + "statusBarItem.hoverBackground": "#9b78b8", + "statusBarItem.remoteBackground": "#8257a6", + "statusBarItem.remoteForeground": "#e7e7e7" + }, + "peacock.color": "#8257a6" } diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md index b0ab6ea..2f3f1c4 100644 --- a/CODE_OF_CONDUCT.md +++ b/CODE_OF_CONDUCT.md @@ -5,19 +5,19 @@ Version: 1.1 Apache 2.0 license, derived from the Apache Foundation Code of Conduct. Also, CC BY-SA 3.0 derived from the Mozilla Community Participation Guidelines. -Our goal is to cultivate a safe, friendly, and inclusive space that benefits all participants in the zkSync ecosystem. +Our goal is to cultivate a safe, friendly, and inclusive space that benefits all participants in the ZKsync ecosystem. This Code of Conduct outlines our shared values and expectations to help ensure that the community remains a positive and enriching environment for everyone. ## When and how to use this Code of Conduct -This is your guide for engaging as a participant in the zkSync ecosystem. -It applies to all physical and digital spaces related to zkSync. +This is your guide for engaging as a participant in the ZKsync ecosystem. +It applies to all physical and digital spaces related to ZKsync. ## Expected behaviors **Be ethical**: -We endeavor to enrich the zkSync ecosystem, while not infringing on the rights and wellbeing of others. -We also endeavor to enrich ourselves without causing harm to the zkSync community. +We endeavor to enrich the ZKsync ecosystem, while not infringing on the rights and wellbeing of others. +We also endeavor to enrich ourselves without causing harm to the ZKsync community. We do not encourage tax evasion, promoting information leaks, speculating on tokens or token prices, or otherwise breaking the law. **Be kind and respectful**: @@ -25,7 +25,7 @@ Treat everyone with kindness, empathy, and respect. We all come from different backgrounds, perspectives and experiences, so let's celebrate our differences and foster a culture of openness and understanding. We may have strong feelings about other layer 1 and layer 2 blockchains, -but that is no reason to disparage, defame, or slander any competitor to zkSync or what other chains are doing. +but that is no reason to disparage, defame, or slander any competitor to ZKsync or what other chains are doing. Feel free to compare metrics and features, but keep to the facts and be respectful of all the builders in web3 trying to advance freedom through blockchain technology! @@ -50,7 +50,7 @@ We encourage questions, and redirect them to the appropriate channel if we do no Communication is key. Use clear and considerate language in your interactions. We aim to create a welcoming environment for users of all ages, so please avoid excessive profanity or explicit content. -Remember that zkSync community members are a diverse bunch. +Remember that ZKsync community members are a diverse bunch. English is our primary working language, but to help others where English is not their first language, be succinct and avoid acronyms where possible. @@ -76,7 +76,7 @@ This includes, but is not limited to: - Advocating for, or encouraging, any of the above behavior. **Have fun and connect**: -Finally, remember that ZK Squad and the zkSync community is a place to connect, learn, and enjoy. +Finally, remember that ZK Squad and the ZKsync community is a place to connect, learn, and enjoy. Participate in a manner that encourages positive interactions and enhances the experiences of all. ## Managing violations diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e175226..e55d230 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,12 +1,12 @@ # How to Contribute Guides to Community Code -We are always glad for new contributions from community members to spread the zkSync knowledge! +We are always glad for new contributions from community members to spread the ZKsync knowledge! If you are interested in adding a new guide to the Community Code, this is the section for you. If you are looking to contribute project changes like fixing bugs, please checkout the [Readme](README.md). ## Fork the project -Make a [fork of the project](https://github.com/zkSync-Community-Hub/community-code/fork) and create your branches from the default `main` branch. +Make a [fork of the project](https://github.com/ZKsync-Community-Hub/community-code/fork) and create your branches from the default `main` branch. If your PR is still a work in progress, consider putting it into a [Draft status](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/changing-the-stage-of-a-pull-request#converting-a-pull-request-to-a-draft). Once your PR is ready for review, switch it back to an active PR request @@ -73,7 +73,7 @@ In markdown, the syntax changes to the following: You can refer to the Nuxt Content documentation on [Vue Components](https://content.nuxt.com/usage/markdown#vue-components) to learn further how to customize and use vue components in markdown. We have additional custom components aside from Nuxt UI that you can use. -You can discover these in our [zkSync Docs Contribution Styleguide](https://docs.zksync.io/build/contributing-to-documentation/documentation-styleguide#markdown-and-vue). +You can discover these in our [ZKsync Docs Contribution Styleguide](https://docs.zksync.io/build/contributing-to-documentation/documentation-styleguide#markdown-and-vue). ## ๐Ÿ’ˆ Writing styleguide @@ -82,12 +82,12 @@ This means our readers may be non-native English speakers. To help everyone learn and grow with our Community Code, we adhere to industry best practices to ensure inclusivity. -Check out and read through our [zkSync Docs Contribution Styleguide](https://docs.zksync.io/build/contributing-to-documentation/documentation-styleguide#writing-style) +Check out and read through our [ZKsync Docs Contribution Styleguide](https://docs.zksync.io/build/contributing-to-documentation/documentation-styleguide#writing-style) to learn how to best write your guide for our community. ## ๐Ÿ“ฅ Submitting your guide -Please [submit a PR of your branch to main on GitHub](https://github.com/zkSync-Community-Hub/community-code/compare). +Please [submit a PR of your branch to main on GitHub](https://github.com/ZKsync-Community-Hub/community-code/compare). Provide a clear description of what you're contributing. ## ๐Ÿ“œ Commit conventions diff --git a/README.md b/README.md index 09a51c6..a78babb 100644 --- a/README.md +++ b/README.md @@ -6,9 +6,9 @@ [![Contributions Welcome](https://img.shields.io/badge/contributions-welcome-orange)](CONTRIBUTING.md) [![X (formerly Twitter) Follow](https://badgen.net/badge/twitter/@zksyncDevs/1DA1F2?icon&label)](https://x.com/zksyncDevs) -Welcome to the zkSync Community Code repository. This project serves as the community hub for zkSync, providing comprehensive +Welcome to the ZKsync Community Code repository. This project serves as the community hub for ZKsync, providing comprehensive documentation for developers written by developers. -Whether you're a beginner looking to get started with zkSync or an experienced developer +Whether you're a beginner looking to get started with ZKsync or an experienced developer seeking advanced guides, you'll find the resources you need here. ## ๐Ÿš€ Quick Start @@ -92,8 +92,8 @@ Check out our [Contributing guide](CONTRIBUTING.md) to learn how to add your own ## ๐Ÿ‘ช Join the community If you haven't already, join our community! -We have [GitHub Discussions](https://github.com/zkSync-Community-Hub/zksync-developers/discussions) +We have [GitHub Discussions](https://github.com/ZKsync-Community-Hub/zksync-developers/discussions) for developers to ask questions and share their work. We also have a [Discord server](https://join.zksync.dev/) for real-time conversations with the team and community. -Be sure to [follow us on Twitter](https://x.com/zkSyncDevs) to keep up to date with announcements from the zkSync dev team. +Be sure to [follow us on Twitter](https://x.com/ZKsyncDevs) to keep up to date with announcements from the ZKsync dev team. diff --git a/SUPPORT.md b/SUPPORT.md index 387fb24..36840e8 100644 --- a/SUPPORT.md +++ b/SUPPORT.md @@ -7,22 +7,22 @@ We have multiple channels available for you to request help. If you are in need of help with submitting your guide to the Community Code, first read through the [Contributing doc](CONTRIBUTING.md) to see if it may help answer some questions. -If the answer is not found, submit an [issue in GitHub](https://github.com/zkSync-Community-Hub/community-code/issues). +If the answer is not found, submit an [issue in GitHub](https://github.com/ZKsync-Community-Hub/community-code/issues). -We also have resources available on the [zksync-developers Discussions](https://github.com/zkSync-Community-Hub/zksync-developers/discussions) +We also have resources available on the [zksync-developers Discussions](https://github.com/ZKsync-Community-Hub/zksync-developers/discussions) where you can submit a question. We also have a [Discord community](https://join.zksync.dev/) that may help with any troubleshooting, check out the `๐Ÿ–ฅโ”‚dev-general` channel. -If you have questions related to any of our zkSync tools, +If you have questions related to any of our ZKsync tools, we recommend that you submit an Issue related to that project. You can find the list of our open-source repositories in the [Contribution Track](https://docs.zksync.io/build/resources/contribution-track) -on our zkSync Docs site. +on our ZKsync Docs site. ## ๐Ÿชฒ Submit a bug report for a guide Are you going through a guide in our Code Community and came across a bug? Perhaps the versions are out of date or a particular tool is broken when trying to run a project. -Submit an [issue in GitHub](https://github.com/zkSync-Community-Hub/community-code/issues) using our Issue form +Submit an [issue in GitHub](https://github.com/ZKsync-Community-Hub/community-code/issues) using our Issue form or submit it directly from the Guide you're working from! In the left sidebar on the site, there is a link at the bottom for "Submit an issue" which will set up a pre-filled Issue form for the particular guide you're on. diff --git a/app.config.ts b/app.config.ts index d270a45..38f49d0 100644 --- a/app.config.ts +++ b/app.config.ts @@ -1,12 +1,12 @@ export default defineAppConfig({ seo: { - siteName: 'zkSync Community Code', + siteName: 'ZKsync Community Code', }, header: { links: [ { icon: 'i-simple-icons-github', - to: 'https://github.com/zkSync-Community-Hub/community-code', + to: 'https://github.com/ZKsync-Community-Hub/community-code', target: '_blank', 'aria-label': 'Community Code on GitHub', title: 'Community Code on GitHub', diff --git a/app.vue b/app.vue index 9e14caf..90bf660 100644 --- a/app.vue +++ b/app.vue @@ -20,15 +20,15 @@ useSeoMeta({ ogSiteName: seo?.siteName, ogUrl: 'https://code.zksync.io', description: - 'Build together with the zkSync Community. Learn how to build amazing smart contracts and dApps on zkSync Era.', + 'Build together with the ZKsync Community. Learn how to build amazing smart contracts and dApps on ZKsync Era.', ogDescription: - 'Build together with the zkSync Community. Learn how to build amazing smart contracts and dApps on zkSync Era.', + 'Build together with the ZKsync Community. Learn how to build amazing smart contracts and dApps on ZKsync Era.', twitterTitle: `%s`, twitterDescription: - 'Build together with the zkSync Community. Learn how to build amazing smart contracts and dApps on zkSync Era.', + 'Build together with the ZKsync Community. Learn how to build amazing smart contracts and dApps on ZKsync Era.', twitterCard: 'summary_large_image', twitterSite: '@zksync', - twitterCreator: '@zkSyncDevs', + twitterCreator: '@ZKsyncDevs', twitterImageAlt: 'Hyperscaling Ethereum with ZK tech.', }); diff --git a/content/_partials/_callout-zksync-cli.md b/content/_partials/_callout-zksync-cli.md index 9992784..dc7db77 100644 --- a/content/_partials/_callout-zksync-cli.md +++ b/content/_partials/_callout-zksync-cli.md @@ -1,11 +1,11 @@ --- -title: Callout zkSync CLI +title: Callout ZKsync CLI --- ::callout{icon="i-heroicons-light-bulb"} Skip the hassle for test ETH by using `zksync-cli` for local testing. -Simply execute `npx zksync-cli dev start` to initialize a local zkSync development environment, -which includes local Ethereum and zkSync nodes. +Simply execute `npx zksync-cli dev start` to initialize a local ZKsync development environment, +which includes local Ethereum and ZKsync nodes. This method allows you to test contracts without requesting external testnet funds. Explore more in the [zksync-cli documentation](https://docs.zksync.io/build/tooling/zksync-cli). :: diff --git a/content/index.yml b/content/index.yml index 007da39..ca3821d 100644 --- a/content/index.yml +++ b/content/index.yml @@ -1,6 +1,6 @@ -title: 'zkSync Community Code' +title: 'ZKsync Community Code' features: - title: 'Community Contributed Guides for zkSync' + title: 'Community Contributed Guides for ZKsync' links: - label: 'Explore community guides' trailingIcon: 'i-heroicons-arrow-right-20-solid' diff --git a/content/tutorials/cross-chain-governance/10.index.md b/content/tutorials/cross-chain-governance/10.index.md index 14cfa54..0af07eb 100644 --- a/content/tutorials/cross-chain-governance/10.index.md +++ b/content/tutorials/cross-chain-governance/10.index.md @@ -1,25 +1,25 @@ --- title: L1 governance contract -description: Build and deploy a smart contract in L1 and send transactions that update the state of a contract in zkSync. +description: Build and deploy a smart contract in L1 and send transactions that update the state of a contract in ZKsync. --- This tutorial shows you how to implement communication between L1 and L2 with the following example: - A **Governance** Solidity smart contract is deployed on layer 1. This contract has a function that sends a transaction - to zkSync layer 2. -- A **Counter** Solidity smart contract is deployed on zkSync layer 2. This contract stores a number that is incremented + to ZKsync layer 2. +- A **Counter** Solidity smart contract is deployed on ZKsync layer 2. This contract stores a number that is incremented by calling the `increment` method. The `Governance` contract on layer 1 calls this function. ## Prerequisites - Make sure your machine satisfies the [system requirements](https://github.com/matter-labs/era-compiler-solidity/tree/main#system-requirements). -- You are already familiar with deploying smart contracts on zkSync Era. +- You are already familiar with deploying smart contracts on ZKsync Era. If not, please refer to the first section of the [quickstart tutorial](https://docs.zksync.io/build/quick-start). - You already have some experience working with Ethereum. - A wallet with sufficient Sepolia `%%zk_testnet_currency_symbol%%` on Ethereum and %%zk_testnet_name%% to pay for deploying smart contracts. You can get Sepolia ETH from the [network faucets](https://docs.zksync.io/ecosystem/network-faucets). - - Get testnet `ETH` for zkSync Era using [bridges](https://zksync.io/explore#bridges) to bridge funds to zkSync. + - Get testnet `ETH` for ZKsync Era using [bridges](https://zksync.io/explore#bridges) to bridge funds to ZKsync. - You know how to get your [private key from your MetaMask wallet](https://support.metamask.io/hc/en-us/articles/360015289632-How-to-export-an-account-s-private-key). :display-partial{path="/_partials/_callout-zksync-cli"} @@ -42,7 +42,7 @@ mkdir L1-governance ::callout{icon="i-heroicons-exclamation-circle"} The `L1-governance` code is a default Hardhat project used to deploy a contract on L1. -The `L2-counter` code includes all zkSync dependencies and configurations for L2. +The `L2-counter` code includes all ZKsync dependencies and configurations for L2. :: ## L1 Governance @@ -58,8 +58,8 @@ npx hardhat Select the option **Create a Typescript project** and accept the defaults for everything else. ::callout{icon="i-heroicons-exclamation-circle"} -To interact with the zkSync bridge contract using Solidity, you need -the zkSync contract interface. There are two ways to get it: +To interact with the ZKsync bridge contract using Solidity, you need +the ZKsync contract interface. There are two ways to get it: - Import it from the `@matterlabs/zksync-contracts` npm package (preferred). - Download it from the [contracts repo](https://github.com/matter-labs/era-contracts). diff --git a/content/tutorials/cross-chain-governance/20.L2-contract.md b/content/tutorials/cross-chain-governance/20.L2-contract.md index 59e2282..42fd0a9 100644 --- a/content/tutorials/cross-chain-governance/20.L2-contract.md +++ b/content/tutorials/cross-chain-governance/20.L2-contract.md @@ -1,6 +1,6 @@ --- title: L2 counter contract -description: Deploy a contract in zkSync that has a counter. +description: Deploy a contract in ZKsync that has a counter. --- ## L2 Counter @@ -19,7 +19,7 @@ Now that we have an address for the L1 governance contract, we can build, deploy Clean your current environment in advance or create another folder and create environment there. :: -1. For the purposes of this tutorial, we don't need the Greeter related files generated by the zkSync-CLI. +1. For the purposes of this tutorial, we don't need the Greeter related files generated by the ZKsync-CLI. Proceed with removing `Greeter.sol` from our `/contracts` directory: ```sh @@ -126,7 +126,7 @@ Now that we have an address for the L1 governance contract, we can build, deploy If your wallet already has funds in L2, you can skip that part to save you some time. :: -1. Now deploy the contract from the `L2-counter/` folder root to zkSync: +1. Now deploy the contract from the `L2-counter/` folder root to ZKsync: ::code-group @@ -300,9 +300,9 @@ Now, let's call the `increment` method on Layer 2 from Layer 1. // Initialize the L2 provider. const l2Provider = new Provider("https://sepolia.era.zksync.dev"); - // Get the current address of the zkSync L1 bridge. + // Get the current address of the ZKsync L1 bridge. const zkSyncAddress = await l2Provider.getMainContractAddress(); - // Get the `Contract` object of the zkSync bridge. + // Get the `Contract` object of the ZKsync bridge. const zkSyncContract = new Contract(zkSyncAddress, utils.ZKSYNC_MAIN_ABI, wallet); // Encoding the L1 transaction is done in the same way as it is done on Ethereum. @@ -372,7 +372,7 @@ Now, let's call the `increment` method on Layer 2 from Layer 1. :: In the output, you should see the full transaction receipt in L2. - You can take the `transactionHash` and track it in the [zkSync explorer](https://sepolia.explorer.zksync.io/). + You can take the `transactionHash` and track it in the [ZKsync explorer](https://sepolia.explorer.zksync.io/). It should look something like this: ```json @@ -411,9 +411,9 @@ Now, let's call the `increment` method on Layer 2 from Layer 1. ## Learn More -- To learn more about L1->L2 interaction on zkSync, check out the +- To learn more about L1->L2 interaction on ZKsync, check out the [documentation](https://docs.zksync.io/build/developer-reference/l1-l2-interoperability). - To learn more about the `zksync-ethers` SDK, check out its [documentation](https://docs.zksync.io/sdk/ethers/v6/getting-started). -- To learn more about the zkSync hardhat plugins, check out their +- To learn more about the ZKsync hardhat plugins, check out their [documentation](https://docs.zksync.io/build/tooling/hardhat/getting-started). diff --git a/content/tutorials/cross-chain-governance/30.cross-chain-transactions.md b/content/tutorials/cross-chain-governance/30.cross-chain-transactions.md index ac76d18..71cb85c 100644 --- a/content/tutorials/cross-chain-governance/30.cross-chain-transactions.md +++ b/content/tutorials/cross-chain-governance/30.cross-chain-transactions.md @@ -1,6 +1,6 @@ --- title: L1-L2 transactions -description: Deploy a contract in zkSync that has a counter. +description: Deploy a contract in ZKsync that has a counter. --- ## Call L2 Contract from L1 @@ -98,9 +98,9 @@ Now, let's call the `increment` method on Layer 2 from Layer 1. // Initialize the L2 provider. const l2Provider = new Provider("https://sepolia.era.zksync.dev"); - // Get the current address of the zkSync L1 bridge. + // Get the current address of the ZKsync L1 bridge. const zkSyncAddress = await l2Provider.getMainContractAddress(); - // Get the `Contract` object of the zkSync bridge. + // Get the `Contract` object of the ZKsync bridge. const zkSyncContract = new Contract(zkSyncAddress, utils.ZKSYNC_MAIN_ABI, wallet); // Encoding the L1 transaction is done in the same way as it is done on Ethereum. @@ -151,7 +151,7 @@ Now, let's call the `increment` method on Layer 2 from Layer 1. Executing transactions from L1 requires the caller to pay a fee to the L2 operator. The fee depends on the length of the calldata and the `gasLimit`. This is similar to the `gasLimit` on Ethereum. - You can read more about the [zkSync fee model here](https://docs.zksync.io/build/developer-reference/fee-model). + You can read more about the [ZKsync fee model here](https://docs.zksync.io/build/developer-reference/fee-model). The fee also depends on the gas price that is used during the transaction call. So to have a predictable fee for the call, the gas price should be fetched from the L1 provider. :: @@ -210,9 +210,9 @@ Now, let's call the `increment` method on Layer 2 from Layer 1. ## Learn More -- To learn more about L1->L2 interaction on zkSync, check out the +- To learn more about L1->L2 interaction on ZKsync, check out the [documentation](https://docs.zksync.io/build/developer-reference/l1-l2-interoperability). - To learn more about the `zksync-ethers` SDK, check out its [documentation](https://docs.zksync.io/sdk/ethers/v6/getting-started). -- To learn more about the zkSync hardhat plugins, check out their +- To learn more about the ZKsync hardhat plugins, check out their [documentation](https://docs.zksync.io/build/tooling/hardhat/getting-started). diff --git a/content/tutorials/cross-chain-governance/_dir.yml b/content/tutorials/cross-chain-governance/_dir.yml index ff953a2..969f053 100644 --- a/content/tutorials/cross-chain-governance/_dir.yml +++ b/content/tutorials/cross-chain-governance/_dir.yml @@ -4,15 +4,15 @@ authors: - name: MatterLabs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - smart contracts - L1-L2 - tutorial -summary: Build and deploy a smart contract in L1 and send transactions that update the state of a contract in zkSync. +summary: Build and deploy a smart contract in L1 and send transactions that update the state of a contract in ZKsync. description: - In this tutorial we'll deploy a simple smart contract in zkSync. Then we'll deploy another smart contract in L1 and - send transactions that update the state of the contract in zkSync. We'll use the Mailbox + In this tutorial we'll deploy a simple smart contract in ZKsync. Then we'll deploy another smart contract in L1 and + send transactions that update the state of the contract in ZKsync. We'll use the Mailbox what_you_will_learn: - How to deploy smart contracts in L1 and L2. - How to send transactions in L1 that interact with contracts in L2. diff --git a/content/tutorials/daily-spend-limit-account/10.index.md b/content/tutorials/daily-spend-limit-account/10.index.md index 404321e..f72312a 100644 --- a/content/tutorials/daily-spend-limit-account/10.index.md +++ b/content/tutorials/daily-spend-limit-account/10.index.md @@ -3,7 +3,7 @@ title: Daily spending limit account description: Build a native smart contract account that has a daily spend limit. --- -This tutorial shows you how to create a smart contract account with a daily spending limit using the zkSync Era native +This tutorial shows you how to create a smart contract account with a daily spending limit using the ZKsync Era native account abstraction. The daily limit feature prevents an account from spending more ETH than the limit set by the account's owner. @@ -13,13 +13,13 @@ The daily limit feature prevents an account from spending more ETH than the limi - Make sure your machine satisfies the [system requirements](https://github.com/matter-labs/era-compiler-solidity/tree/main#system-requirements). - [Node.js](https://nodejs.org/en/download/) and [Yarn](https://classic.yarnpkg.com/lang/en/docs/install/#mac-stable) are installed on your machine. -- You are already familiar with deploying smart contracts on zkSync Era. +- You are already familiar with deploying smart contracts on ZKsync Era. If not, please refer to the first section of the [quickstart tutorial](https://docs.zksync.io/build/quick-start). - A wallet with sufficient Sepolia `%%zk_testnet_currency_symbol%%` on Ethereum and %%zk_testnet_name%% to pay for deploying smart contracts. You can get Sepolia ETH from the [network faucets](https://docs.zksync.io/ecosystem/network-faucets). - - Get testnet `ETH` for zkSync Era using [bridges](https://zksync.io/explore#bridges) to bridge funds to zkSync. + - Get testnet `ETH` for ZKsync Era using [bridges](https://zksync.io/explore#bridges) to bridge funds to ZKsync. - You know how to get your [private key from your MetaMask wallet](https://support.metamask.io/hc/en-us/articles/360015289632-How-to-export-an-account-s-private-key). -- We encourage you to read [the basics of account abstraction on zkSync Era](https://docs.zksync.io/build/developer-reference/account-abstraction/introduction) +- We encourage you to read [the basics of account abstraction on ZKsync Era](https://docs.zksync.io/build/developer-reference/account-abstraction/introduction) and complete the [multisig account tutorial](/tutorials/native-aa-multisig) before attempting this tutorial. :display-partial{path="/_partials/_callout-zksync-cli"} @@ -27,7 +27,7 @@ The daily limit feature prevents an account from spending more ETH than the limi ## Complete Project Download the [complete project on GitHub](https://github.com/matter-labs/tutorials/tree/main/spend-limit). -Additionally, the repository contains a test folder with more detailed tests for running on a zkSync Era local network. +Additionally, the repository contains a test folder with more detailed tests for running on a ZKsync Era local network. ::callout{icon="i-heroicons-exclamation-circle"} This entire tutorial can be run in under a minute using Atlas. @@ -37,7 +37,7 @@ Atlas is a smart contract IDE that lets you write, deploy, and interact with con ## Project Setup -We will use the [zkSync Era Hardhat plugins](https://docs.zksync.io/build/tooling/hardhat/getting-started) to build, deploy, and interact +We will use the [ZKsync Era Hardhat plugins](https://docs.zksync.io/build/tooling/hardhat/getting-started) to build, deploy, and interact with the smart contracts in this project. 1. Initiate a new project by running the command: @@ -46,7 +46,7 @@ with the smart contracts in this project. npx zksync-cli create custom-spendlimit-tutorial --template hardhat_solidity ``` - This creates a new zkSync Era project called `custom-spendlimit-tutorial` with a with a few example contracts. + This creates a new ZKsync Era project called `custom-spendlimit-tutorial` with a with a few example contracts. 1. Navigate into the project directory: @@ -62,7 +62,7 @@ with the smart contracts in this project. rm -rf ./deploy/* ``` -1. Add the zkSync and OpenZeppelin contract libraries: +1. Add the ZKsync and OpenZeppelin contract libraries: ```sh yarn add -D @matterlabs/zksync-contracts @openzeppelin/contracts@4.9.5 @@ -503,7 +503,7 @@ import "@matterlabs/zksync-contracts/l2/system-contracts/libraries/TransactionHe import "@openzeppelin/contracts/interfaces/IERC1271.sol"; // Used for signature validation import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; -// Access zkSync system contracts for nonce validation via NONCE_HOLDER_SYSTEM_CONTRACT +// Access ZKsync system contracts for nonce validation via NONCE_HOLDER_SYSTEM_CONTRACT import "@matterlabs/zksync-contracts/l2/system-contracts/Constants.sol"; // to call non-view function of system contracts import "@matterlabs/zksync-contracts/l2/system-contracts/libraries/SystemContractsCaller.sol"; @@ -732,7 +732,7 @@ contract Account is IAccount, IERC1271, SpendLimit { :: ::callout{icon="i-heroicons-exclamation-triangle"} -The formal ETH address on zkSync Era is +The formal ETH address on ZKsync Era is `0x000000000000000000000000000000000000800a`. Neither the well-known `0xEee...EEeE` used by protocols as a placeholder on Ethereum, nor the zero address `0x000...000`, that ([`zksync-ethers` provides](https://docs.zksync.io/build/developer-reference/era-contracts/l1-contracts)) has a more user-friendly alias. @@ -824,7 +824,7 @@ contract AAFactory { const factoryArtifact = await deployer.loadArtifact("AAFactory"); const aaArtifact = await deployer.loadArtifact("Account"); - // Bridge funds if the wallet on zkSync doesn't have enough funds. + // Bridge funds if the wallet on ZKsync doesn't have enough funds. // const depositAmount = ethers.parseEther('0.1'); // const depositHandle = await deployer.zkWallet.deposit({ // to: deployer.zkWallet.address, @@ -1115,11 +1115,11 @@ Let's test the `SpendLimit` contract works to make it refuse ETH transfers that ## Learn More -- To learn more about L1->L2 interaction on zkSync, check out the +- To learn more about L1->L2 interaction on ZKsync, check out the [documentation](https://docs.zksync.io/build/developer-reference/l1-l2-interoperability). - To learn more about the `zksync-ethers` SDK, check out its [documentation](https://docs.zksync.io/sdk/ethers/v6/getting-started). -- To learn more about the zkSync hardhat plugins, check out their +- To learn more about the ZKsync hardhat plugins, check out their [documentation](https://docs.zksync.io/build/tooling/hardhat/getting-started). ## Credits diff --git a/content/tutorials/daily-spend-limit-account/_dir.yml b/content/tutorials/daily-spend-limit-account/_dir.yml index 0b222bd..cedbd5f 100644 --- a/content/tutorials/daily-spend-limit-account/_dir.yml +++ b/content/tutorials/daily-spend-limit-account/_dir.yml @@ -4,7 +4,7 @@ authors: - name: porco-rosso url: https://linktr.ee/porcorossoj avatar: https://ugc.production.linktr.ee/EwAEHlJtSE2axYbN9Rbq_Q1QGRK751VjBz7QQ?io=true&size=avatar-v3_0 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - account abstraction - smart contracts diff --git a/content/tutorials/dapp-nft-paymaster/10.index.md b/content/tutorials/dapp-nft-paymaster/10.index.md index 9e36e94..49ca884 100644 --- a/content/tutorials/dapp-nft-paymaster/10.index.md +++ b/content/tutorials/dapp-nft-paymaster/10.index.md @@ -17,10 +17,11 @@ By the end of this tutorial, you will: ### Introduction Welcome to this hands-on tutorial on creating and interacting with an `ERC721GatedPaymaster` and interacting with a -front-end application. If you've ever been curious about the mechanisms that allow for gasless transactions on zkSync -Era and our native account abstraction capabilities you're in the right place! +front-end application. +If you've ever been curious about the mechanisms that allow for gasless transactions +on ZKsync Era and our native account abstraction capabilities you're in the right place! -You'll gain a thorough understanding of how to create, compile, and deploy smart contracts on zkSync Era, delve into the +You'll gain a thorough understanding of how to create, compile, and deploy smart contracts on ZKsync Era, delve into the intricacies of paymasters and validation logic, and seamlessly integrate them within a frontend application. On completion, you'll have a fully functional `ERC721GatedPaymaster` contract and an interactive frontend to go with it. @@ -28,7 +29,7 @@ completion, you'll have a fully functional `ERC721GatedPaymaster` contract and a - Make sure your machine satisfies the [system requirements](https://github.com/matter-labs/era-compiler-solidity/tree/main#system-requirements). - A [Node.js](https://nodejs.org/en/download) installation running at minimum Node.js version 16. -- You are already familiar with deploying smart contracts on zkSync Era. +- You are already familiar with deploying smart contracts on ZKsync Era. If not, please refer to the first section of the [quickstart tutorial](https://docs.zksync.io/build/quick-start). - Some background knowledge on the concepts covered by the tutorial would be helpful too. Have a look at the following docs: diff --git a/content/tutorials/dapp-nft-paymaster/20.smart-contracts.md b/content/tutorials/dapp-nft-paymaster/20.smart-contracts.md index 6729b6b..4c79cbd 100644 --- a/content/tutorials/dapp-nft-paymaster/20.smart-contracts.md +++ b/content/tutorials/dapp-nft-paymaster/20.smart-contracts.md @@ -24,8 +24,8 @@ Letโ€™s first break down the project structure within `/zksync`: โ””โ”€โ”€ yarn.lock ``` -The template provides a ready-to-use `hardhat.config.ts` file that targets zkSync Era Testnet. If you are unfamiliar -with zkSync Era Hardhat configurations please refer to the documentation +The template provides a ready-to-use `hardhat.config.ts` file that targets %%zk_testnet_name%%. If you are unfamiliar +with ZKsync Era Hardhat configurations please refer to the documentation [here](https://docs.zksync.io/build/tooling/hardhat/getting-started). 1. To configure your private key, copy the `.env.example` file, rename the copy to `.env`, and add your wallet private @@ -38,7 +38,7 @@ with zkSync Era Hardhat configurations please refer to the documentation Your private key will be used for paying the costs of deploying the smart contract. ::callout{icon="i-heroicons-light-bulb"} - A heads up! Make sure your account has zkSync Era Sepolia Testnet or Sepolia + A heads up! Make sure your account has %%zk_testnet_name%% or Sepolia ETH to successfully deploy the contracts. :: @@ -370,7 +370,7 @@ of the paymaster. But before we deploy the contracts we first need to compile th Balance of the recipient: 1 New baseURI is https://ipfs.io/ipfs/QmPtDtJEJDzxthbKmdgvYcLa9oNUUUkh7vvz5imJFPQdKx Your verification ID is: 34297 - Contract successfully verified on zkSync block explorer! + Contract successfully verified on ZKsync block explorer! contracts/ERC721.sol:InfinityStones verified! VerificationId: 34297 Done! Running deploy script for the ERC721GatedPaymaster contract... @@ -379,7 +379,7 @@ of the paymaster. But before we deploy the contracts we first need to compile th Funding paymaster with ETH Paymaster ETH balance is now 5000000000000000 Your verification ID is: 34298 - Contract successfully verified on zkSync block explorer! + Contract successfully verified on ZKsync block explorer! contracts/ERC721GatedPaymaster.sol:ERC721GatedPaymaster verified! VerificationId: 34298 Done! Running deploy script for the Greeter contract @@ -387,9 +387,9 @@ of the paymaster. But before we deploy the contracts we first need to compile th Constructor args:0x000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000094869207468657265210000000000000000000000000000000000000000000000 Greeter was deployed to 0x19720a45b7aB632Cc380A33E0964bc90013CCB2e Your verification ID is: 34299 - Contract successfully verified on zkSync block explorer! + Contract successfully verified on ZKsync block explorer! Done! ``` -We have successfully compiled and deployed our smart contracts to zkSync Era Testnet! +We have successfully compiled and deployed our smart contracts to %%zk_testnet_name%%! Let's move over to the `/frontend` directory to interact with these smart contracts. diff --git a/content/tutorials/dapp-nft-paymaster/30.frontend.md b/content/tutorials/dapp-nft-paymaster/30.frontend.md index 3321d31..e2062cd 100644 --- a/content/tutorials/dapp-nft-paymaster/30.frontend.md +++ b/content/tutorials/dapp-nft-paymaster/30.frontend.md @@ -306,7 +306,7 @@ Ensure you connect the address that received the minted NFT during contract depl ## Conclusion -As we conclude, you've not only set up and run a seamless integration between a frontend and zkSync Era Testnet +As we conclude, you've not only set up and run a seamless integration between a frontend and %%zk_testnet_name%% but have also gained hands-on expertise. You've connected your MetaMask, engaged with smart contracts, and seen the magic of paymasters unfold right on your local server. diff --git a/content/tutorials/dapp-nft-paymaster/_dir.yml b/content/tutorials/dapp-nft-paymaster/_dir.yml index 15213f8..3fb8629 100644 --- a/content/tutorials/dapp-nft-paymaster/_dir.yml +++ b/content/tutorials/dapp-nft-paymaster/_dir.yml @@ -3,7 +3,7 @@ authors: - name: MatterLabs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - paymaster - frontend @@ -12,7 +12,7 @@ tags: - ERC721 summary: Build a frontend that allows users to interact smart contracts with zero transaction fees wif they hold an NFT. description: - This tutorial will guide you through the process of building a frontend that interacts with smart contracts on zkSync. + This tutorial will guide you through the process of building a frontend that interacts with smart contracts on ZKsync. The frontend will enable gasless transactions for users that hold a specific NFT thanks to a paymaster. what_you_will_learn: - How to build frontend diff --git a/content/tutorials/erc20-paymaster/10.index.md b/content/tutorials/erc20-paymaster/10.index.md index 9db77bd..cb543f2 100644 --- a/content/tutorials/erc20-paymaster/10.index.md +++ b/content/tutorials/erc20-paymaster/10.index.md @@ -16,9 +16,9 @@ You will: - Make sure your machine satisfies the [system requirements](https://github.com/matter-labs/era-compiler-solidity/tree/main#system-requirements). - A [Node.js](https://nodejs.org/en/download) installation running at minimum Node.js version 16. -- You are already familiar with deploying smart contracts on zkSync Era. +- You are already familiar with deploying smart contracts on ZKsync Era. If not, please refer to the first section of the [quickstart tutorial](https://docs.zksync.io/build/quick-start). -- You are already familiar with deploying smart contracts on zkSync Era. +- You are already familiar with deploying smart contracts on ZKsync Era. If not, please refer to the first section of the [quickstart tutorial](https://docs.zksync.io/build/quick-start). - Some background knowledge on the concepts covered by the tutorial would be helpful too. Have a look at the following docs: @@ -46,7 +46,7 @@ Atlas is a smart contract IDE that lets you write, deploy, and interact with con npx zksync-cli create custom-paymaster-tutorial --template hardhat_solidity ``` - This creates a new zkSync Era project called `custom-paymaster-tutorial` with a basic `Greeter` contract. + This creates a new ZKsync Era project called `custom-paymaster-tutorial` with a basic `Greeter` contract. 1. Navigate into the project directory: @@ -566,18 +566,18 @@ The paymaster paid the fees for the mint transaction with ETH. ``` please try sending additional ETH to the paymaster so it has enough funds to pay for the transaction. - You can use [zkSync native bridge or ecosystem partners](https://zksync.io/explore#bridges) (make sure Sepolia testnet is supported by selected bridge). + You can use [ZKsync native bridge or ecosystem partners](https://zksync.io/explore#bridges) (make sure Sepolia testnet is supported by selected bridge). - If the `use-paymaster.ts` script fails when minting new ERC20 tokens with the error `Error: transaction failed`, -and the transactions appear with status "Failed" in the [zkSync explorer](https://explorer.zksync.io/), +and the transactions appear with status "Failed" in the [ZKsync explorer](https://explorer.zksync.io/), please reach out to us on [our Discord](https://join.zksync.dev/). As a workaround, try including a specific `gasLimit` value in the transaction. ## Learn More -- To learn more about L1->L2 interaction on zkSync, check out the +- To learn more about L1->L2 interaction on ZKsync, check out the [documentation](https://docs.zksync.io/build/developer-reference/l1-l2-interoperability). - To learn more about the `zksync-ethers` SDK, check out its [documentation](https://docs.zksync.io/sdk/ethers/v6/getting-started). -- To learn more about the zkSync hardhat plugins, check out their +- To learn more about the ZKsync hardhat plugins, check out their [documentation](https://docs.zksync.io/build/tooling/hardhat/getting-started). diff --git a/content/tutorials/erc20-paymaster/_dir.yml b/content/tutorials/erc20-paymaster/_dir.yml index 46e6dd5..ba74de6 100644 --- a/content/tutorials/erc20-paymaster/_dir.yml +++ b/content/tutorials/erc20-paymaster/_dir.yml @@ -4,7 +4,7 @@ authors: - name: MatterLabs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - account abstraction - paymaster diff --git a/content/tutorials/frontend-paymaster/10.index.md b/content/tutorials/frontend-paymaster/10.index.md index 239ab1a..25acaf6 100644 --- a/content/tutorials/frontend-paymaster/10.index.md +++ b/content/tutorials/frontend-paymaster/10.index.md @@ -1,18 +1,18 @@ --- title: Frontend Quickstart, build your first dApp -description: Build a frontend that allows users to interact smart contracts paying fees with ERC20 tokens on zkSync. +description: Build a frontend that allows users to interact smart contracts paying fees with ERC20 tokens on ZKsync. --- ::callout{icon="i-heroicons-light-bulb"} Although this tutorial can be used as a reference -to understand how to create frontends to interact with smart contracts deployed to zkSync, +to understand how to create frontends to interact with smart contracts deployed to ZKsync, it requires a smart contract already deployed. :: In this tutorial we're going to: -- Create a basic frontend to interact with a smart contract deployed in zkSync. -- Learn about `zksync-ethers` and use it to connect to zkSync and interact with our contract. +- Create a basic frontend to interact with a smart contract deployed in ZKsync. +- Learn about `zksync-ethers` and use it to connect to ZKsync and interact with our contract. - Learn about paymasters. - Integrate a paymaster in our frontend to allow users to pay transaction fees in any ERC20 token. @@ -25,8 +25,8 @@ In this tutorial we're going to: The easiest way is to [mint TEST tokens](https://sepolia.explorer.zksync.io/address/0x7E2026D8f35872923F5459BbEDDB809F6aCEfEB3#contract) directly in our explorer. You can also get Sepolia USDC or DAI from [the Aave faucet](https://staging.aave.com/faucet/) - and then bridge them to zkSync using [the zkSync bridge](https://portal.zksync.io/bridge/?network=sepolia). -- Complete [the zkSync 101 tutorials](https://docs.zksync.io/build/zksync-101) to deploy a smart contract. + and then bridge them to ZKsync using [the ZKsync bridge](https://portal.zksync.io/bridge/?network=sepolia). +- Complete [the ZKsync 101 tutorials](https://docs.zksync.io/build/zksync-101) to deploy a smart contract. ## Setup the project @@ -131,7 +131,7 @@ import * as GREETER_CONTRACT_ABI from './abi.json' // TODO: Complete and import ::callout{icon="i-heroicons-light-bulb"} -- To interact with a smart contract deployed to zkSync, we need its ABI. +- To interact with a smart contract deployed to ZKsync Era, we need its ABI. - ABI stands for Application Binary Interface and it's a JSON which describes the contract's variables and methods. :: @@ -199,7 +199,7 @@ import * as GREETER_CONTRACT_ABI from './abi.json' // TODO: Complete and import The `initializeProviderAndSigner` function in `./src/App.vue` is called right after the connection to Metamask is successful. In this function we should: -- Initialize a `BrowserProvider` and a `Signer` to interact with zkSync. +- Initialize a `BrowserProvider` and a `Signer` to interact with ZKsync. - Initialize the `Contract` object to interact with the `Greeter` contract we deployed previously. 1. Import the necessary classes from `zksync-ethers` in the import statement we added previously: @@ -236,7 +236,7 @@ const getGreeting = async () => { }; ``` -Now if you go back to your browser, after connecting the Metamask wallet to zkSync Era Testnet, you should see the following page: +Now if you go back to your browser, after connecting the Metamask wallet to %%zk_testnet_name%%, you should see the following page: !['Retrieve message from contract'](/images/frontend-paymaster/quickstart-hello-nofee.jpeg) @@ -333,7 +333,7 @@ Now you can update the greeting message in the contract via a transaction sent w Once the transaction is processed, you will see the Greeter message change on the app. Congrats! You now have a fully functional Greeter-dApp! -However, it does not yet leverage any zkSync-specific features. +However, it does not yet leverage any ZKsync-specific features. Let's fix that by integrating a paymaster! ::callout{icon="i-heroicons-exclamation-triangle"} @@ -346,7 +346,7 @@ Read more about `wallet_requestPermissions`, in the [MetaMask documentation](htt ## Pay Fees with ERC20 Tokens -zkSync Era has native account abstraction, a feature that allows application developers to integrate paymasters. +ZKsync Era has native account abstraction, a feature that allows application developers to integrate paymasters. You can find more information about paymasters in [this section of our docs](https://docs.zksync.io/build/developer-reference/account-abstraction/paymasters) but the TL;DR is the following: @@ -357,7 +357,7 @@ but the TL;DR is the following: - To integrate a paymaster in your app, transactions must include specific parameters as transaction overrides in a custom property called `paymasterParams`. We will use the [testnet paymaster](https://docs.zksync.io/build/developer-reference/account-abstraction/paymasters#testnet-paymaster) -that is provided on all zkSync Era testnets. +that is provided on all ZKsync Era testnets. ::callout{icon="i-heroicons-light-bulb"} **The testnet paymaster allows users to pay fees in any ERC20 token with a fixed exchange rate of 1:1 - Token:ETH**, @@ -376,7 +376,7 @@ The `getOverrides` function returns an empty object when users decide to pay wit when users select the ERC20 option, it should return the paymaster address and all the information required to interact with it. Let's see how it's done. -1. To retrieve the address of the testnet paymaster we'll use the `getTestnetPaymasterAddress` method from the zkSync provider. +1. To retrieve the address of the testnet paymaster we'll use the `getTestnetPaymasterAddress` method from the ZKsync provider. This is one of the zksync-specific methods provided by `zksync-ethers`: ```javascript @@ -498,7 +498,7 @@ Let's see how it's done. ``` The `ApprovalBased` type in the `paymasterParams` indicates that this paymaster allows ERC20 tokens. - Behind the scenes, zkSync will take care of approve the ERC20 spending. + Behind the scenes, ZKsync Era will take care of approve the ERC20 spending. 1. To enable the use a list of ERC20 tokens, change the following line: @@ -540,10 +540,10 @@ Now you should be able to update the greeting message with ETH or any of the ava ## Next steps -- For an overview of security and best practices for developing on zkSync Era, +- For an overview of security and best practices for developing on ZKsync Era, refer to the [Security and best practices page](https://docs.zksync.io/build/developer-reference/.best-practices). - To learn more about the `zksync-ethers` SDK, check out its [documentation](https://docs.zksync.io/sdk/ethers/v6/getting-started). -- To learn more about the zkSync hardhat plugins, check out their +- To learn more about the ZKsync hardhat plugins, check out their [documentation](https://docs.zksync.io/build/tooling/hardhat/getting-started). - If you have a project, check out our [migration guide](https://docs.zksync.io/build/tooling/hardhat/migrating-to-zksync). diff --git a/content/tutorials/frontend-paymaster/_dir.yml b/content/tutorials/frontend-paymaster/_dir.yml index 11f719b..326b771 100644 --- a/content/tutorials/frontend-paymaster/_dir.yml +++ b/content/tutorials/frontend-paymaster/_dir.yml @@ -3,15 +3,15 @@ authors: - name: MatterLabs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - paymaster - frontend - vue.js - tutorial -summary: Build a frontend that allows users to interact smart contracts paying fees with ERC20 tokens on zkSync. +summary: Build a frontend that allows users to interact smart contracts paying fees with ERC20 tokens on ZKsync. description: - This tutorial will guide you through the process of building a frontend that interacts with smart contracts on zkSync. + This tutorial will guide you through the process of building a frontend that interacts with smart contracts on ZKsync. The frontend will allow users to pay fees with any ERC20 tokens using a paymaster. what_you_will_learn: - How to build frontend diff --git a/content/tutorials/guide-dipdup-indexer/10.index.md b/content/tutorials/guide-dipdup-indexer/10.index.md index 436a594..e9f3a5f 100644 --- a/content/tutorials/guide-dipdup-indexer/10.index.md +++ b/content/tutorials/guide-dipdup-indexer/10.index.md @@ -66,7 +66,7 @@ which is implemented in demo. Let's look further into it in following steps. In the project root, you'll find a file named `dipdup.yaml`. It's the main configuration file of your indexer. We will discuss it in detail in the [Config](https://dipdup.io/docs/getting-started/config) section; -for now just replace contract address with target token, I will use zkSync USDT for this example: +for now just replace contract address with target token, I will use ZKsync USDT for this example: ```yaml [dipdup.yaml] spec_version: 2.0 @@ -106,7 +106,7 @@ indexes: Now, let's examine `handlers/on_transfer.py`. As defined in `dipdup.yaml`, this handler is activated when the transfer method of the token contract is called. -In this guide, we focus on tracking USDT balances on zkSync: +In this guide, we focus on tracking USDT balances on ZKsync Era: ```py [on_transfer.py] from decimal import Decimal diff --git a/content/tutorials/guide-subquery/10.index.md b/content/tutorials/guide-subquery/10.index.md index 08d807f..f380b12 100644 --- a/content/tutorials/guide-subquery/10.index.md +++ b/content/tutorials/guide-subquery/10.index.md @@ -1,6 +1,6 @@ --- title: Indexing events with SubQuery -description: This guide outlines the process of indexing all transfers and approval events from the Wrapped ETH on zkSync Era Network. +description: This guide outlines the process of indexing all transfers and approval events from the Wrapped ETH on ZKsync Era Network. --- [The SubQuery Network](https://academy.subquery.network/) indexes and services data to the global community in an incentivized and verifiable way. @@ -60,8 +60,8 @@ yarn install ### Configure Your Project Manifest File -The `project.yaml` file serves as the entry point to your zkSync project, defining how SubQuery will index and transform the chain data. -For zkSync Era, three types of mapping handlers are available: +The `project.yaml` file serves as the entry point to your ZKsync project, defining how SubQuery will index and transform the chain data. +For ZKsync Era, three types of mapping handlers are available: - `BlockHandlers`: Executes a mapping function on every block. - `TransactionHandlers`: Executes a mapping function on each transaction matching optional filter criteria. diff --git a/content/tutorials/guide-subquery/_dir.yml b/content/tutorials/guide-subquery/_dir.yml index d4661a6..b50ae47 100644 --- a/content/tutorials/guide-subquery/_dir.yml +++ b/content/tutorials/guide-subquery/_dir.yml @@ -9,7 +9,7 @@ tags: - SubQuery summary: This page will guide you through the steps to index smart contract events using SubQuery. description: - This guide outlines the process of indexing all transfers and approval events from the Wrapped ETH on zkSync Era + This guide outlines the process of indexing all transfers and approval events from the Wrapped ETH on ZKsync Era Network. what_you_will_learn: - How to use Subquery diff --git a/content/tutorials/guide-the-graph/10.index.md b/content/tutorials/guide-the-graph/10.index.md index 9a5a7b2..f637cdf 100644 --- a/content/tutorials/guide-the-graph/10.index.md +++ b/content/tutorials/guide-the-graph/10.index.md @@ -7,12 +7,12 @@ Deploying graphs is a great way to query data from network historically and in r [The Graph](https://thegraph.com/) is a decentralized protocol for indexing and querying data from blockchains. The Graph serves queries over data that is easily stored, decentralized, and secured by the blockchain. -You will learn how to deploy a subgraph that tracks a specific address on zkSync Era mainnet. +You will learn how to deploy a subgraph that tracks a specific address on %%zk_mainnet_name%%. ### Prerequisites - **Knowledge Base**: Familiarity with Typescript. -- **Wallet Setup**: Have MetaMask installed and Setup, ensuring there's a balance on the zkSync Testnet. +- **Wallet Setup**: Have MetaMask installed and Setup, ensuring there's a balance on the %%zk_testnet_name%%. - **Tooling**: This guide utilizes `@graphprotocol/graph-cli`. Ensure you have it accessible or installed in your environment. ### Understanding subgraphs @@ -36,7 +36,7 @@ Visit [https://thegraph.com/studio/](https://thegraph.com/studio/), connect your - [Create subgraph](https://thegraph.com/studio) -Enter the name of the subgraph, and select the zkSync Era as the network: +Enter the name of the subgraph, and select the ZKsync Era as the network: ![Install graphcli](/images/thegraph/Screenshot-2023-09-25-4.35.png) @@ -176,5 +176,5 @@ Query the `bridgeMints` table for a specific `account` address: ### Conclusion -In this tutorial, you learned how to deploy a subgraph that tracks a specific address on zkSync Era. -Build a frontend application that interacts with the subgraph and is reliant on data from zkSync Era! +In this tutorial, you learned how to deploy a subgraph that tracks a specific address on ZKsync Era. +Build a frontend application that interacts with the subgraph and is reliant on data from ZKsync Era! diff --git a/content/tutorials/guide-the-graph/_dir.yml b/content/tutorials/guide-the-graph/_dir.yml index c5e94d9..fab199b 100644 --- a/content/tutorials/guide-the-graph/_dir.yml +++ b/content/tutorials/guide-the-graph/_dir.yml @@ -9,7 +9,7 @@ tags: - theGraph summary: This page will guide you through the steps to index smart contract data using theGraph. description: - This guide outlines the process of indexing all transfers and approval events from the Wrapped ETH on zkSync Era + This guide outlines the process of indexing all transfers and approval events from the Wrapped ETH on ZKsync Era Network. what_you_will_learn: - How to use theGraph diff --git a/content/tutorials/guide-viem/10.index.md b/content/tutorials/guide-viem/10.index.md index 41be7cb..d9de37d 100644 --- a/content/tutorials/guide-viem/10.index.md +++ b/content/tutorials/guide-viem/10.index.md @@ -1,14 +1,14 @@ --- -title: Using viem with zkSync -description: Learn how to use the viem/zksync plugin to interact with zkSync. +title: Using viem with ZKsync +description: Learn how to use the viem/zksync plugin to interact with ZKsync. --- -[viem](https://viem.sh/) is a TypeScript interface for Ethereum that now includes support for zkSync, -offering low-level stateless primitives for interacting with both Ethereum and zkSync. -You can use viem to interact seamlessly with smart contracts deployed on zkSync. -For more information on zkSync specific support please refer to viem documentation [here](https://viem.sh/docs/chains/zksync). +[viem](https://viem.sh/) is a TypeScript interface for Ethereum that now includes support for ZKsync, +offering low-level stateless primitives for interacting with both Ethereum and ZKsync. +You can use viem to interact seamlessly with smart contracts deployed on ZKsync. +For more information on ZKsync specific support please refer to viem documentation [here](https://viem.sh/docs/chains/zksync). -You can use viem to interact with smart contracts deployed on zkSync. +You can use viem to interact with smart contracts deployed on ZKsync. ## Installation @@ -36,7 +36,7 @@ import { zkSyncSepoliaTestnet } from "viem/chains"; // Initialize the Viem client const client = createPublicClient({ - chain: zkSyncSepoliaTestnet, // Specify the zkSync network + chain: zkSyncSepoliaTestnet, // Specify the ZKsync network transport: http(), // Define the transport method }); ``` @@ -50,7 +50,7 @@ const client = createPublicClient({ ### Reading Data -Access zkSync data by invoking Public Actions that mirror Ethereum RPC methods. +Access ZKsync data by invoking Public Actions that mirror Ethereum RPC methods. #### Fetch the Latest Block Number @@ -91,10 +91,10 @@ client.sendTransaction({ [Paymasters](https://docs.zksync.io/build/developer-reference/account-abstraction.html#paymasters) cover transaction fees, facilitating a smoother user experience. -To utilize zkSync's native account abstraction and Paymasters, extend the Wallet client with `eip712WalletActions`: +To utilize ZKsync Era's native account abstraction and Paymasters, extend the Wallet client with `eip712WalletActions`: #### Setup - + ```javascript import 'viem/window'; import { createWalletClient, custom } from 'viem'; @@ -107,7 +107,7 @@ const walletClient = createWalletClient({ transport: custom(window.ethereum!), }).extend(eip712WalletActions()); ``` - + #### Sending a Transaction with a Paymaster ```javascript @@ -156,7 +156,7 @@ const hash = await walletClient.writeContract({ address: "0xFBA3912Ca04dd458c843e2EE08967fC04f3579c2", abi: parseAbi(["function setGreeting(string _greeting) nonpayable"]), functionName: "setGreeting", - args: ["zkSync!"], + args: ["ZKsync!"], paymaster: paymasterAddress, paymasterInput: params.paymasterInput, }); diff --git a/content/tutorials/guide-viem/_dir.yml b/content/tutorials/guide-viem/_dir.yml index ec303fb..22f0a8c 100644 --- a/content/tutorials/guide-viem/_dir.yml +++ b/content/tutorials/guide-viem/_dir.yml @@ -8,14 +8,14 @@ github_repo: https://github.com/matter-labs tags: - guide - viem -summary: This page will explain how to use the viem/zksync plugin to interact with zkSync. +summary: This page will explain how to use the viem/zksync plugin to interact with ZKsync. description: - This guide outlines how to use the zkSync viem plugin to interact with zkSync and use specific actions like sending + This guide outlines how to use the ZKsync viem plugin to interact with ZKsync and use specific actions like sending transcations via paymasters. what_you_will_learn: - - How to install viem and the zkSync plugin + - How to install viem and the ZKsync plugin - How to send RPC requests to zkSync - - How to use zkSync-specific methods + - How to use ZKsync-specific methods updated: 2024-05-09 tools: - viem diff --git a/content/tutorials/guide-wagmi/10.index.md b/content/tutorials/guide-wagmi/10.index.md index 33c3857..4da524c 100644 --- a/content/tutorials/guide-wagmi/10.index.md +++ b/content/tutorials/guide-wagmi/10.index.md @@ -1,9 +1,9 @@ --- -title: Using Wagmi with zkSync -description: Learn how to use the Wagmi toolkit to create websites that interact with contracts on zkSync +title: Using Wagmi with ZKsync +description: Learn how to use the Wagmi toolkit to create websites that interact with contracts on ZKsync --- -The `@wagmi/core` library provides a comprehensive VanillaJS toolkit for interacting with zkSync Era. +The `@wagmi/core` library provides a comprehensive VanillaJS toolkit for interacting with ZKsync Era. It simplifies wallet connections, balance retrieval, message signing, and contract interactions. For setup instructions, consult the official documentation [here](https://wagmi.sh/core/getting-started). @@ -14,7 +14,7 @@ Wagmi hooks do not yet support Paymasters and native Account Abstraction; develo Here are some common actions: ## Connect Wallet - + ```typescript import { w3mConnectors, w3mProvider } from "@web3modal/ethereum"; import { configureChains, createConfig } from "wagmi"; @@ -40,7 +40,7 @@ export const config = createConfig({ export { chains }; ``` - + ## Display Wallet Options ```typescript diff --git a/content/tutorials/guide-wagmi/_dir.yml b/content/tutorials/guide-wagmi/_dir.yml index cb4c3d6..a403657 100644 --- a/content/tutorials/guide-wagmi/_dir.yml +++ b/content/tutorials/guide-wagmi/_dir.yml @@ -1,4 +1,4 @@ -title: Using wagmi with zkSync +title: Using wagmi with ZKsync authors: - name: MatterLabs url: https://matter-labs.io @@ -7,14 +7,14 @@ github_repo: https://github.com/matter-labs tags: - guide - wagmi -summary: Learn how to use the Wagmi toolkit to create websites that interact with contracts on zkSync +summary: Learn how to use the Wagmi toolkit to create websites that interact with contracts on ZKsync description: - This guide outlines how to use the wagmi library to create websites that interact with zkSync contracts. We provide + This guide outlines how to use the wagmi library to create websites that interact with ZKsync contracts. We provide some examples to help you get started. what_you_will_learn: - - How to use wagmi to interact with zkSync - - How to fetch data from zkSync contracts - - How to send transactions to zkSync contracts + - How to use wagmi to interact with ZKsync + - How to fetch data from ZKsync contracts + - How to send transactions to ZKsync contracts updated: 2024-05-09 tools: - wagmi diff --git a/content/tutorials/guide-walletconnect/10.index.md b/content/tutorials/guide-walletconnect/10.index.md index 151f5ce..ffde0c2 100644 --- a/content/tutorials/guide-walletconnect/10.index.md +++ b/content/tutorials/guide-walletconnect/10.index.md @@ -1,9 +1,9 @@ --- -title: Using WalletConnect with zkSync -description: Learn how to use WalletConnect to create React apps that interact with contracts on zkSync. +title: Using WalletConnect with ZKsync +description: Learn how to use WalletConnect to create React apps that interact with contracts on ZKsync. --- -Using WalletConnect with zkSync Era is fast and easy. Below is a quick example to get you started. +Using WalletConnect with ZKsync Era is fast and easy. Below is a quick example to get you started. WalletConnect's [Web3Modal React](https://docs.walletconnect.com/web3modal/react/about#introduction) integrates with the Wagmi library, offering a suite of React Hooks to streamline your dapp development. @@ -43,7 +43,7 @@ then create `wagmiConfig` using `defaultWagmiConfig` function as shown below. Finally, pass `wagmiConfig` to `createWeb3Modal`. Find an example below: - + ```ts import React from "react"; import ReactDOM from "react-dom/client"; @@ -94,5 +94,6 @@ ReactDOM.createRoot(document.getElementById("root") as HTMLElement).render( , ); ``` + You can find more information about how to integrate Web3Modal in the [WalletConnect documentation](https://docs.walletconnect.com/web3modal/react/about#implementation). diff --git a/content/tutorials/guide-walletconnect/_dir.yml b/content/tutorials/guide-walletconnect/_dir.yml index c16701f..70c53e9 100644 --- a/content/tutorials/guide-walletconnect/_dir.yml +++ b/content/tutorials/guide-walletconnect/_dir.yml @@ -1,15 +1,15 @@ -title: Using WalletConnect with zkSync +title: Using WalletConnect with ZKsync authors: - - name: MatterLabs + - name: Matter Labs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 github_repo: https://github.com/matter-labs tags: - guide - WalletConnect -summary: Learn how to use WalletConnect to create React apps that interact with contracts on zkSync. +summary: Learn how to use WalletConnect to create React apps that interact with contracts on ZKsync. description: - This guide outlines how to use WalletConnect and Web3Modal to create React apps that interact with contracts on zkSync + This guide outlines how to use WalletConnect and Web3Modal to create React apps that interact with contracts on ZKsync what_you_will_learn: - How to use WalletConnect - How to use Web3Modal diff --git a/content/tutorials/guide-web3js/10.index.md b/content/tutorials/guide-web3js/10.index.md index 90747d8..014f0d8 100644 --- a/content/tutorials/guide-web3js/10.index.md +++ b/content/tutorials/guide-web3js/10.index.md @@ -1,31 +1,31 @@ --- -title: Using Web3.js to interact with zkSync -description: Learn how to use Web3js to interact with zkSync and use built-in functions for zkSync-specific JSON RPC methods. +title: Using Web3.js to interact with ZKsync +description: Learn how to use Web3js to interact with ZKsync and use built-in functions for ZKsync-specific JSON RPC methods. --- [Web3.js](https://web3js.org/) is a robust and flexible collection of libraries for TypeScript and JavaScript developers. It serves as an essential tool for connecting and crafting applications within the Ethereum ecosystem and can be extended to support other networks through its [plugin system](https://docs.web3js.org/guides/web3_plugin_guide/). -You can use the [zkSync plugin](https://github.com/web3/web3-plugin-zksync) for Web3.js -to interact with the [zkSync JSON-RPC API](https://docs.zksync.io/build/api.html) smart contracts deployed on zkSync. +You can use the [ZKsync plugin](https://github.com/web3/web3-plugin-zksync) for Web3.js +to interact with the [ZKsync JSON-RPC API](https://docs.zksync.io/build/api.html) smart contracts deployed on ZKsync. ## Installation -Start by adding Web3.js and the zkSync plugin for Web3.js to your project. +Start by adding Web3.js and the ZKsync plugin for Web3.js to your project. Open your terminal and execute the following command: ```bash npm install --save web3 web3-plugin-zksync ``` -This command installs the latest version of Web3.js and the zkSync plugin for Web3.js and adds them to your project's dependencies. +This command installs the latest version of Web3.js and the ZKsync plugin for Web3.js and adds them to your project's dependencies. ## Initial Setup ### Initialization -Before using the zkSync plugin for Web3.js, you need to [initialize Web3 with a provider](https://docs.web3js.org/#initialize-web3-with-a-provider) +Before using the ZKsync plugin for Web3.js, you need to [initialize Web3 with a provider](https://docs.web3js.org/#initialize-web3-with-a-provider) and [register the plugin](https://docs.web3js.org/guides/web3_plugin_guide/plugin_users#registering-the-plugin). #### Example @@ -36,7 +36,7 @@ import { ZkSyncPlugin } from "web3-plugin-zksync"; const zkSyncRpcUrl: string = "https://sepolia.era.zksync.dev"; -console.log(`๐Ÿ“ž Connecting to zkSync Era [${zkSyncRpcUrl}]`); +console.log(`๐Ÿ“ž Connecting to ZKsync Era [${zkSyncRpcUrl}]`); const web3: Web3 = new Web3(zkSyncRpcUrl); web3.registerPlugin(new ZkSyncPlugin()); ``` @@ -47,7 +47,7 @@ This examples uses the %%zk_testnet_name%%. ### Ethereum JSON-RPC API -Use the Web3.js `eth` package to fetch data from the zkSync [Ethereum JSON-RPC API](https://docs.zksync.io/build/api-reference/ethereum-rpc). +Use the Web3.js `eth` package to fetch data from the ZKsync [Ethereum JSON-RPC API](https://docs.zksync.io/build/api-reference/ethereum-rpc). #### Fetch the Latest Block Number @@ -56,9 +56,9 @@ const blockNumber = await web3.eth.getBlockNumber(); console.log(`Current block number: ${blockNumber}`); ``` -### zkSync L2-Specific JSON-RPC API +### ZKsync L2-Specific JSON-RPC API -The zkSync plugin for Web3.js implements the zkSync-specific methods +The ZKsync plugin for Web3.js implements the ZKsync-specific methods from the `zks_` namespace of the [JSON-RPC API](https://docs.zksync.io/build/api.html#zksync-era-json-rpc-methods). #### Fetch the Main Contract Address diff --git a/content/tutorials/guide-web3js/_dir.yml b/content/tutorials/guide-web3js/_dir.yml index a863321..c3a7095 100644 --- a/content/tutorials/guide-web3js/_dir.yml +++ b/content/tutorials/guide-web3js/_dir.yml @@ -1,4 +1,4 @@ -title: Using web3.js to interact with zkSync +title: Using web3.js to interact with ZKsync featured: true authors: - name: ChainSafe @@ -8,12 +8,12 @@ github_repo: https://github.com/ChainSafe tags: - guide - web3.js -summary: This page will guide you through the steps to use web3.js to interact with zkSync. -description: This guide outlines how to use the zkSync web3.js plugin to interact with zkSync. +summary: This page will guide you through the steps to use web3.js to interact with ZKsync. +description: This guide outlines how to use the ZKsync web3.js plugin to interact with ZKsync. what_you_will_learn: - - How to install web3.js and the zkSync plugin - - How to send RPC requests to zkSync - - How to use zkSync-specific methods + - How to install web3.js and the ZKsync plugin + - How to send RPC requests to ZKsync + - How to use ZKsync-specific methods updated: 2024-05-09 tools: - web3.js diff --git a/content/tutorials/how-to-deploy-contract/10.index.md b/content/tutorials/how-to-deploy-contract/10.index.md index 6578705..bf4d6b6 100644 --- a/content/tutorials/how-to-deploy-contract/10.index.md +++ b/content/tutorials/how-to-deploy-contract/10.index.md @@ -1,6 +1,6 @@ --- -title: Deploy Contracts to zkSync -description: Learn how to deploy smart contracts to zkSync +title: Deploy Contracts to ZKsync +description: Learn how to deploy smart contracts to ZKsync --- This guide provides a step-by-step guide for deploying smart contracts on the %%zk_testnet_name%% network, @@ -13,13 +13,13 @@ using capabilities of Hardhat together with the `hardhat-zksync-deploy` and `har - Initialized Hardhat TypeScript project - A wallet with sufficient Sepolia `%%zk_testnet_currency_symbol%%` on Ethereum and %%zk_testnet_name%% to pay for deploying smart contracts. You can get Sepolia ETH from the [network faucets](https://docs.zksync.io/ecosystem/network-faucets). - - Get testnet `ETH` for zkSync Era using [bridges](https://zksync.io/explore#bridges) to bridge funds to zkSync. + - Get testnet `ETH` for ZKsync Era using [bridges](https://zksync.io/explore#bridges) to bridge funds to ZKsync. - You know how to get your [private key from your MetaMask wallet](https://support.metamask.io/hc/en-us/articles/360015289632-How-to-export-an-account-s-private-key). ## Deployment using hardhat-zksync-deploy One way to deploy smart contracts is by using the **hardhat-zksync-deploy** plugin, -which offers utilities for deploying smart contracts on zkSync Era with artifacts +which offers utilities for deploying smart contracts on ZKsync Era with artifacts generated by either the **@matterlabs/hardhat-zksync-solc** or **@matterlabs/hardhat-zksync-vyper** plugins. Check **hardhat-zksync-deploy** documentation [here](https://docs.zksync.io/build/tooling/hardhat/hardhat-zksync-deploy). @@ -118,9 +118,9 @@ const config: HardhatUserConfig = { defaultNetwork: "zkTestnet", networks: { zkTestnet: { - url: "%%zk_testnet_rpc_url%%", // The RPC URL of zkSync Era network. + url: "%%zk_testnet_rpc_url%%", // The RPC URL of ZKsync Era network. ethNetwork: "https://sepolia.infura.io/v3/", // The Ethereum Web3 RPC URL. - zksync: true, // Flag that targets zkSync Era. + zksync: true, // Flag that targets ZKsync Era. }, }, }; @@ -133,11 +133,11 @@ In the configuration above we have some important fields such as: - `solidity` - enabling adjustment and customization of the solc compiler. - `defaultNetwork` - specifying which network is default to use when running hardhat tasks. - `networks` - define which networks we can use in our development. Only one network is used at the time. - - `url` is a field containing the URL of the zkSync Era node in case of the zkSync Era network (with zksync flag set to true), - or the URL of the Ethereum node. This field is required for all zkSync Era and Ethereum networks. + - `url` is a field containing the URL of the ZKsync Era node in case of the ZKsync Era network (with zksync flag set to true), + or the URL of the Ethereum node. This field is required for all ZKsync Era and Ethereum networks. - `ethNetwork` is a field with the URL of the Ethereum node. You can also provide network name (e.g. sepolia) as the value of this field. In this case, the plugin will either use the URL of the appropriate Ethereum network configuration (from the networks section), or the default. - - `zksync` is a flag that indicates if the network is zkSync Era. This field needs to be set to true for all zkSync Era networks; it is false by default + - `zksync` is a flag that indicates if the network is ZKsync Era. This field needs to be set to true for all ZKsync Era networks; it is false by default Find more details about available configuration options in the [official documentation.](https://docs.zksync.io/build/tooling/hardhat/hardhat-zksync-solc#configuration) @@ -152,7 +152,7 @@ yarn hardhat compile After successful compilation, you should see the output similar to this: ```bash -Compiling contracts for zkSync Era with zksolc v1.3.22 and solc v0.8.17 +Compiling contracts for ZKsync Era with zksolc v1.3.22 and solc v0.8.17 Compiling 1 Solidity file Successfully compiled 1 Solidity file Done in 0.69s. @@ -294,7 +294,7 @@ if (!PRIVATE_KEY) { ```bash { - url: 'https://sepolia.era.zksync.dev', // you should use the URL of the zkSync network RPC + url: 'https://sepolia.era.zksync.dev', // you should use the URL of the ZKsync network RPC ethNetwork: 'sepolia', zksync: true, accounts:[PRIVATE_KEY] // put your private key here @@ -322,7 +322,7 @@ Instead, scripts will be stored within the `scripts` folder and executed using t #### Usage of getWallet helper method -Since we aim to deploy contracts to the `zkSync Sepolia Testnet`, +Since we aim to deploy contracts to the `ZKsync Sepolia Testnet`, and considering we've configured an `account` section inside the network settings in the **hardhat.config.ts**, we can automatically connect the default wallet to the network. All helper methods for deployments will utilize this approach under the hood, diff --git a/content/tutorials/how-to-deploy-contract/_dir.yml b/content/tutorials/how-to-deploy-contract/_dir.yml index d159aaa..561e09b 100644 --- a/content/tutorials/how-to-deploy-contract/_dir.yml +++ b/content/tutorials/how-to-deploy-contract/_dir.yml @@ -1,16 +1,16 @@ title: How to deploy a contract authors: - - name: MatterLabs + - name: Matter Labs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - hardhat - smart contracts - how-to -summary: Learn how to deploy a smart contract on zkSync. +summary: Learn how to deploy a smart contract on ZKsync. description: - This how-to guide explains how to deploy a smart contract on zkSync using hardhat-zksync-deploy and + This how-to guide explains how to deploy a smart contract on ZKsync using hardhat-zksync-deploy and hardhat-zksync-ethers. what_you_will_learn: - How to compile smart contracts diff --git a/content/tutorials/how-to-deposit-erc20/10.index.md b/content/tutorials/how-to-deposit-erc20/10.index.md index ea16172..437a37b 100644 --- a/content/tutorials/how-to-deposit-erc20/10.index.md +++ b/content/tutorials/how-to-deposit-erc20/10.index.md @@ -1,11 +1,11 @@ --- -title: Deposit ERC20 tokens to zkSync -description: Learn how to create a script to deposit any ERC20 token to zkSync. +title: Deposit ERC20 tokens to ZKsync +description: Learn how to create a script to deposit any ERC20 token to ZKsync. --- -Depositing ERC-20 tokens from Layer 1 (L1) to Layer 2 (L2) is a vital step to engage with zkSync efficiently. -This guide outlines the process of depositing ERC-20 tokens using the zkSync Javascript SDK, ensuring a streamlined transition of assets to L2. -In zkSync, assets deposited from L1 are secured in a smart contract, +Depositing ERC-20 tokens from Layer 1 (L1) to Layer 2 (L2) is a vital step to engage with ZKsync efficiently. +This guide outlines the process of depositing ERC-20 tokens using the ZKsync Javascript SDK, ensuring a streamlined transition of assets to L2. +In ZKsync, assets deposited from L1 are secured in a smart contract, while corresponding representations are created on L2, paving the way for swift and economical transactions. ## Prerequisites @@ -25,7 +25,7 @@ method on the L1 bridge contract. Here's a simplified breakdown of the process: 1. **Locking L1 Tokens**: Initially, the specified tokens on L1 are sent to the L1 bridge, where they are locked. 2. **Initiating L1 to L2 Transaction**: The L1 bridge then initiates a transaction to the L2 bridge, marking the start of the deposit process. 3. **Minting L2 Tokens**: Tokens corresponding to the deposit are minted on L2 and sent to the designated L2 address. - - If the token contract isnโ€™t already present on zkSync Era, a new contract is deployed with a new L2 token address, + - If the token contract isnโ€™t already present on ZKsync Era, a new contract is deployed with a new L2 token address, which is derived from the original L1 address, name, and symbol. 4. **Confirmation Logging**: Each executed L1 to L2 transaction is confirmed with a log message sent from L2 back to L1. 5. **Finalizing Deposit**: Finally, the @@ -75,7 +75,7 @@ dotenv.config(); // HTTP RPC endpoints const L1_RPC_ENDPOINT = process.env.L1_RPC_ENDPOINT || ""; // or an RPC endpoint from Infura/Chainstack/QuickNode/etc. -const L2_RPC_ENDPOINT = process.env.L2_RPC_ENDPOINT || "%%zk_testnet_rpc_url%%"; // or the zkSync Era mainnet +const L2_RPC_ENDPOINT = process.env.L2_RPC_ENDPOINT || "%%zk_testnet_rpc_url%%"; // or the ZKsync Era mainnet // ERC-20 Token (DAI) address in L1 const TOKEN_ADDRESS = "0x5C221E77624690fff6dd741493D735a17716c26B"; @@ -149,5 +149,5 @@ Deposit transaction sent 0xffb8e302430b0584e2e0104dd6295a03688c98ba7b6e9279b01db ## Conclusion -By adhering to this guide, you have successfully deposited ERC-20 tokens from L1 to L2 using the zkSync Javascript SDK, -making a significant stride towards interacting with the zkSync Era. +By adhering to this guide, you have successfully deposited ERC-20 tokens from L1 to L2 using the ZKsync Javascript SDK, +making a significant stride towards interacting with the ZKsync Era. diff --git a/content/tutorials/how-to-deposit-erc20/_dir.yml b/content/tutorials/how-to-deposit-erc20/_dir.yml index b0d0fcd..29e9fc8 100644 --- a/content/tutorials/how-to-deposit-erc20/_dir.yml +++ b/content/tutorials/how-to-deposit-erc20/_dir.yml @@ -1,18 +1,18 @@ -title: How to deposit ERC20 to zkSync +title: How to deposit ERC20 to ZKsync authors: - - name: MatterLabs + - name: Matter Labs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - hardhat - how-to - erc20 -summary: Learn how to deposit ERC20 tokens zkSync. -description: This how-to guide explains how to create a script that deposits any ERC20 token to zkSync. +summary: Learn how to deposit ERC20 tokens ZKsync. +description: This how-to guide explains how to create a script that deposits any ERC20 token to ZKsync. what_you_will_learn: - How L2 deposits work - - How to deposit ERC20 tokens to zkSync + - How to deposit ERC20 tokens to ZKsync updated: 2024-05-09 tools: - zksync-ethers diff --git a/content/tutorials/how-to-deposit-eth/10.index.md b/content/tutorials/how-to-deposit-eth/10.index.md index 34ace2a..486f016 100644 --- a/content/tutorials/how-to-deposit-eth/10.index.md +++ b/content/tutorials/how-to-deposit-eth/10.index.md @@ -1,11 +1,11 @@ --- -title: Deposit Ether to zkSync -description: Learn how to create a script to deposit Ether to zkSync. +title: Deposit Ether to ZKsync +description: Learn how to create a script to deposit Ether to ZKsync. --- -Depositing assets from L1 to L2 is a fundamental step to interact with zkSync. +Depositing assets from L1 to L2 is a fundamental step to interact with ZKsync. This guide demonstrates how to deposit ETH using the Javascript SDK, ensuring a smooth transition of assets to L2. -In zkSync, assets deposited from L1 are locked in a smart contract +In ZKsync, assets deposited from L1 are locked in a smart contract and corresponding representations of these assets are minted on L2, enabling fast and cheap transactions. @@ -26,7 +26,7 @@ Here's a simplified breakdown of the process: 1. **Locking L1 Tokens**: Initially, the specified tokens on L1 are sent to the L1 bridge, where they are locked. 2. **Initiating L1 to L2 Transaction**: The L1 bridge then initiates a transaction to the L2 bridge, marking the start of the deposit process. 3. **Minting L2 Tokens**: Tokens corresponding to the deposit are minted on L2 and sent to the designated L2 address. - - If the token contract isnโ€™t already present on zkSync Era, a new contract is deployed with a new L2 token address, + - If the token contract isnโ€™t already present on ZKsync Era, a new contract is deployed with a new L2 token address, which is derived from the original L1 address, name, and symbol. 4. **Confirmation Logging**: Each executed L1 to L2 transaction is confirmed with a log message sent from L2 back to L1. 5. **Finalizing Deposit**: Finally, the @@ -76,7 +76,7 @@ dotenv.config(); // HTTP RPC endpoints const L1_RPC_ENDPOINT = process.env.L1_RPC_ENDPOINT || ""; // or an RPC endpoint from Infura/Chainstack/QuickNode/etc. -const L2_RPC_ENDPOINT = process.env.L2_RPC_ENDPOINT || "%%zk_testnet_rpc_url%%"; // or the zkSync Era mainnet +const L2_RPC_ENDPOINT = process.env.L2_RPC_ENDPOINT || "%%zk_testnet_rpc_url%%"; // or the ZKsync Era mainnet // Amount in ETH const AMOUNT = "0.00001"; @@ -142,5 +142,5 @@ Please wait a few minutes for the deposit to be processed in L2 ## Conclusion -By following this guide, you have successfully deposited ETH from L1 to L2 using the zkSync Javascript SDK. -This is a fundamental step towards interacting with the zkSync Era. +By following this guide, you have successfully deposited ETH from L1 to L2 using the ZKsync Javascript SDK. +This is a fundamental step towards interacting with the ZKsync Era. diff --git a/content/tutorials/how-to-deposit-eth/_dir.yml b/content/tutorials/how-to-deposit-eth/_dir.yml index 67dbc04..a5542e6 100644 --- a/content/tutorials/how-to-deposit-eth/_dir.yml +++ b/content/tutorials/how-to-deposit-eth/_dir.yml @@ -1,18 +1,18 @@ -title: How to deposit Ether to zkSync +title: How to deposit Ether to ZKsync authors: - - name: MatterLabs + - name: Matter Labs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - hardhat - how-to - Ether -summary: Learn how to deposit Ether to zkSync. -description: This how-to guide explains how to create a script that deposits Ether to zkSync. +summary: Learn how to deposit Ether to ZKsync. +description: This how-to guide explains how to create a script that deposits Ether to ZKsync. what_you_will_learn: - How L2 deposits work - - How to deposit Ether to zkSync + - How to deposit Ether to ZKsync updated: 2024-05-09 tools: - zksync-ethers diff --git a/content/tutorials/how-to-send-l2-l1-message/10.index.md b/content/tutorials/how-to-send-l2-l1-message/10.index.md index 07f0dc3..c1fcd12 100644 --- a/content/tutorials/how-to-send-l2-l1-message/10.index.md +++ b/content/tutorials/how-to-send-l2-l1-message/10.index.md @@ -1,11 +1,11 @@ --- title: Send a message from L2 to L1 -description: Learn how to send an arbitrary message from a smart contract on zkSync to another contract in Ethereum. +description: Learn how to send an arbitrary message from a smart contract on ZKsync to another contract in Ethereum. --- It is impossible to send transactions directly from L2 to L1. -Instead, you can send arbitrary-length messages from zkSync Era to Ethereum, +Instead, you can send arbitrary-length messages from ZKsync Era to Ethereum, and then handle the received message on Ethereum with an L1 smart contract. #### What is a message? @@ -23,12 +23,12 @@ and then handle the received message on Ethereum with an L1 smart contract. ::callout{icon="i-heroicons-light-bulb"} Verification and confirmation is possible using Ethereum data. -However, zkSync Era has an efficient [request proof function](#retrieve-the-message-proof) which does the same. +However, ZKsync Era has an efficient [request proof function](#retrieve-the-message-proof) which does the same. :: ## Common use cases -Along with zkSync Era's built-in censorship resistance that requires multi-layer interoperability, +Along with ZKsync Era's built-in censorship resistance that requires multi-layer interoperability, there are some common use cases that need L2 to L1 transaction functionality, such as: - Bridging funds from L2 to L1. @@ -95,7 +95,7 @@ there are some common use cases that need L2 to L1 transaction functionality, su ## Send the message -To send a message from L2 to L1, we are going to interact with the zkSync messenger contract. +To send a message from L2 to L1, we are going to interact with the ZKsync messenger contract. Both the address and ABI are provided in the `utils.L1_MESSENGER_ADDRESS` and `utils.L1_MESSENGER` of `zksync-ethers`. The method we're using is `sendToL1` and we're passing the message in UTF8 bytes format. @@ -344,7 +344,7 @@ Create a `4.prove-inclusion.ts` file in the root directory with the next script: :: :: -This scripts interacts with the `proveL2MessageInclusion` method of the zkSync contract on L1. This method requires the following parameters: +This scripts interacts with the `proveL2MessageInclusion` method of the ZKsync contract on L1. This method requires the following parameters: - `l1BatchNumber`: Batch number the L2 transaction was included into. - `proofId`: the `id` of the proof retrieved in step 3. diff --git a/content/tutorials/how-to-send-l2-l1-message/_dir.yml b/content/tutorials/how-to-send-l2-l1-message/_dir.yml index 418fa25..91defc1 100644 --- a/content/tutorials/how-to-send-l2-l1-message/_dir.yml +++ b/content/tutorials/how-to-send-l2-l1-message/_dir.yml @@ -1,18 +1,18 @@ title: How to send an L2->L1 message authors: - - name: MatterLabs + - name: Matter Labs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - smart contracts - how-to - L2-L1 communication -summary: Learn how to send a message from zkSync to Ethereum L1. -description: This how-to guide explains how to send an arbitrary message from zkSync to Ethereum L1. +summary: Learn how to send a message from ZKsync to Ethereum L1. +description: This how-to guide explains how to send an arbitrary message from ZKsync to Ethereum L1. what_you_will_learn: - How L2-L1 communication works - - How to send a message from zkSync to Ethereum L1. + - How to send a message from ZKsync to Ethereum L1. - How to verify the message on Ethereum L1. updated: 2024-05-09 tools: diff --git a/content/tutorials/how-to-test-contracts/10.index.md b/content/tutorials/how-to-test-contracts/10.index.md index 12009fe..11ba47a 100644 --- a/content/tutorials/how-to-test-contracts/10.index.md +++ b/content/tutorials/how-to-test-contracts/10.index.md @@ -5,8 +5,8 @@ description: Learn how to test your smart contracts locally using era-test-node This tutorial provides a step-by-step guide on testing smart contracts using the `hardhat-chai-matchers` plugin -in conjunction with the **zkSync Era Test Node** on your local machine. -To facilitate this process of running tests on the **zkSync Era Test Node**, you'll also utilize the `hardhat-zksync-node` plugin. +in conjunction with the **ZKsync Era Test Node** on your local machine. +To facilitate this process of running tests on the **ZKsync Era Test Node**, you'll also utilize the `hardhat-zksync-node` plugin. ## Prerequisites @@ -16,11 +16,11 @@ To facilitate this process of running tests on the **zkSync Era Test Node**, you ## Era-test-node plugin -In this tutorial, the contract functionality is tested using the [zkSync Era Test Node](https://docs.zksync.io/build/test-and-debug/in-memory-node). +In this tutorial, the contract functionality is tested using the [ZKsync Era Test Node](https://docs.zksync.io/build/test-and-debug/in-memory-node). To start local node we use the `hardhat-zksync-node` plugin to integrate this functionality within the Hardhat project. ::callout{icon="i-heroicons-exclamation-triangle"} -During the alpha phase, zkSync Era Test Nodes are currently undergoing development, wherein certain functionalities might not be fully supported or operational. +During the alpha phase, ZKsync Era Test Nodes are currently undergoing development, wherein certain functionalities might not be fully supported or operational. :: ### Installation @@ -45,9 +45,9 @@ Once installed, add the plugin at the top of your `hardhat.config.ts` file. import "@matterlabs/hardhat-zksync-node"; ``` -### Starting the zkSync Era Test Node +### Starting the ZKsync Era Test Node -You can now safely run the **zkSync Era Test Node** with the following command: +You can now safely run the **ZKsync Era Test Node** with the following command: ::code-group @@ -62,7 +62,7 @@ yarn hardhat node-zksync :: ::callout{icon="i-heroicons-exclamation-circle"} -We'll want to verify the correctness of our installations and test if we can run a **zkSync Era Test Node**, +We'll want to verify the correctness of our installations and test if we can run a **ZKsync Era Test Node**, without further use of this command in the tutorial. :: @@ -78,12 +78,12 @@ You should see output similar to this: 09:04:44 INFO ======================================== ``` -Since we've confirmed that the **zkSync Era Test Node** is functioning properly with the help of the `hardhat-zksync-node` plugin, +Since we've confirmed that the **ZKsync Era Test Node** is functioning properly with the help of the `hardhat-zksync-node` plugin, we can shut it down and continue with the tutorial. ### Integration with Hardhat -To enable the usage of zkSync Era Test Node in Hardhat, add the `zksync:true` option to the hardhat network in the `hardhat.config.ts` file: +To enable the usage of ZKsync Era Test Node in Hardhat, add the `zksync:true` option to the hardhat network in the `hardhat.config.ts` file: ```json networks: { @@ -95,7 +95,7 @@ networks: { ## hardhat-chai-matchers plugin -To leverage zkSync-specific capabilities within the [Chai](https://www.chaijs.com/) assertion library for testing smart contracts, +To leverage ZKsync-specific capabilities within the [Chai](https://www.chaijs.com/) assertion library for testing smart contracts, it's necessary to use the `hardhat-chai-matchers` plugin. In the root directory of your project, execute this command: @@ -204,9 +204,9 @@ describe("Greeter", function () { let contract: Contract; before(async function () { - // Creation of a provider from a network URL adjusted specifically for the zkSync Era Test Node. + // Creation of a provider from a network URL adjusted specifically for the ZKsync Era Test Node. provider = new Provider(hre.network.config.url); - // To ensure proper testing, we need to deploy our contract on the zkSync Era Test Node, for more info check hardhat-zksync-deploy plugin documentation. + // To ensure proper testing, we need to deploy our contract on the ZKsync Era Test Node, for more info check hardhat-zksync-deploy plugin documentation. deployer = new Deployer(hre, new Wallet(RICH_PRIVATE_KEY)); artifact = await deployer.loadArtifact("Greeter"); contract = await deployer.deploy(artifact, ["Hello, world!"]); @@ -258,7 +258,7 @@ However, if you prefer to compile manually, simply run the following command `np :: The `hardhat-zksync-node` plugin overrides the default behavior of the Hardhat `test` task. -It starts the **zkSync Era Test Node** before running tests, executes the tests, +It starts the **ZKsync Era Test Node** before running tests, executes the tests, and then automatically shuts down the node after the test cases are completed. Additionally, the plugin generates a log file named `era_test_node.log`, which indicates the node's activity and transactions made during the tests. diff --git a/content/tutorials/how-to-test-contracts/_dir.yml b/content/tutorials/how-to-test-contracts/_dir.yml index c7dcc23..8c3897b 100644 --- a/content/tutorials/how-to-test-contracts/_dir.yml +++ b/content/tutorials/how-to-test-contracts/_dir.yml @@ -1,15 +1,15 @@ title: How to test contracts with Hardhat authors: - - name: MatterLabs + - name: Matter Labs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - smart contracts - how-to - testing summary: Learn how to test smart contracts with Hardhat -description: This how-to guide explains how to test smart contracts on zkSync using Hardhat. +description: This how-to guide explains how to test smart contracts on ZKsync using Hardhat. what_you_will_learn: - How to install era-test-node. - How to write local tests for smart contracts. diff --git a/content/tutorials/how-to-verify-contracts/10.index.md b/content/tutorials/how-to-verify-contracts/10.index.md index f563f1b..1f8f16f 100644 --- a/content/tutorials/how-to-verify-contracts/10.index.md +++ b/content/tutorials/how-to-verify-contracts/10.index.md @@ -1,6 +1,6 @@ --- title: How to verify contracts with Hardhat -description: Learn how to verify smart contracts deployed to zkSync using Hardhat +description: Learn how to verify smart contracts deployed to ZKsync using Hardhat --- Contract source-code verification ensures that the code running on-chain matches your published code. @@ -12,7 +12,7 @@ This document shows you how to verify your contracts with the `hardhat-zksync` p ## Common use cases -- Transparent contract deployment: using the plugin, developers can deploy their contracts on the zkSync Era network +- Transparent contract deployment: using the plugin, developers can deploy their contracts on the ZKsync Era network with transparency so that users and other developers can independently verify the contract's source code, and ensure it behaves as expected. - Cross-chain interoperability: for contracts operating across multiple chains, verifying contracts on each network @@ -30,7 +30,7 @@ This document shows you how to verify your contracts with the `hardhat-zksync` p npx zksync-cli create verify-greeter-contract --template hardhat_solidity ``` - This creates a new zkSync Era project called `verify-greeter-contract` with a basic `Greeter` contract and all the zkSync plugins and configurations. + This creates a new ZKsync Era project called `verify-greeter-contract` with a basic `Greeter` contract and all the ZKsync plugins and configurations. 1. Proceed by moving into the project directory: @@ -57,8 +57,8 @@ zkSyncMainnet: { }, ``` -- Feel free to assign an arbitrary zkSync Era network name utilizing the `defaultNetwork` property. -- The `verifyURL` attribute directs to the verification endpoint specific to the zkSync network. +- Feel free to assign an arbitrary ZKsync Era network name utilizing the `defaultNetwork` property. +- The `verifyURL` attribute directs to the verification endpoint specific to the ZKsync network. - If you want to verify a smart contract in other supported block explorer you can set `verifyURL` to point to it's verification API URL. For example for [L2scan](https://zksync-era.l2scan.co) on mainnet set `verifyURL` to `https://zksync-era.l2scan.co/api/zksync_contract_verification`. - If you intend to validate a smart contract on Ethereum within the same project, @@ -66,7 +66,7 @@ zkSyncMainnet: { ### `Greeter.sol` contract compilation -The [zkSync CLI](https://docs.zksync.io/build/tooling/zksync-cli) provides a `Greeter.sol` contract we will verify on zkSync Era. +The [ZKsync CLI](https://docs.zksync.io/build/tooling/zksync-cli) provides a `Greeter.sol` contract we will verify on ZKsync Era. Compile the contract using this command: @@ -84,7 +84,7 @@ yarn hardhat compile ### Deploy the `Greeter.sol` contract -The [zkSync CLI](https://docs.zksync.io/build/tooling/zksync-cli) provides a `deploy/deploy-greeter.ts` script that we will use to deploy the Greeter contract. +The [ZKsync CLI](https://docs.zksync.io/build/tooling/zksync-cli) provides a `deploy/deploy-greeter.ts` script that we will use to deploy the Greeter contract. To configure your private key, copy the `.env.example` file, rename the copy to `.env`, and add your wallet private key. @@ -118,7 +118,7 @@ constructor args:0x0000000000000000000000000000000000000000000000000000000000000 The Greeter contract got deployed at 0xE84774C41F096Ba5BafA1439cEE787D9dD1A6b72 ``` -Remember, you need the contract address to verify the contract on zkSync Era. +Remember, you need the contract address to verify the contract on ZKsync Era. ### Verify the contract @@ -358,7 +358,7 @@ If the request was not successful, the return value and printed ID is `-1`. ### UI block explorer alternative -Contract verification in zkSync Era ensures the integrity and trustworthiness of your contracts. -The [Smart Contract Verification in zkSync Era Block Explorer](https://explorer.zksync.io/contracts/verify) +Contract verification in ZKsync Era ensures the integrity and trustworthiness of your contracts. +The [Smart Contract Verification in ZKsync Era Block Explorer](https://explorer.zksync.io/contracts/verify) is a manual UI process for doing the same, ideal for occasional use, while the `hardhat-zksync-verify` plugin facilitates an automated, flexible approach for developers. diff --git a/content/tutorials/how-to-verify-contracts/_dir.yml b/content/tutorials/how-to-verify-contracts/_dir.yml index d31773b..daa22a0 100644 --- a/content/tutorials/how-to-verify-contracts/_dir.yml +++ b/content/tutorials/how-to-verify-contracts/_dir.yml @@ -1,15 +1,15 @@ title: Verify contracts with Hardhat authors: - - name: MatterLabs + - name: Matter Labs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - hardhat - contract verification - how-to -summary: Learn how to deploy a smart contract on zkSync. -description: This how-to guide explains how to verify a smart contract on zkSync using Hardhat. +summary: Learn how to deploy a smart contract on ZKsync. +description: This how-to guide explains how to verify a smart contract on ZKsync using Hardhat. what_you_will_learn: - How to compile smart contracts. - How to verify contracts. diff --git a/content/tutorials/how-to-withdraw-erc20/10.index.md b/content/tutorials/how-to-withdraw-erc20/10.index.md index 642a3a6..4d00e83 100644 --- a/content/tutorials/how-to-withdraw-erc20/10.index.md +++ b/content/tutorials/how-to-withdraw-erc20/10.index.md @@ -1,11 +1,11 @@ --- -title: Withdraw ERC20 tokens from zkSync -description: Learn how to create a script to withdraw any ERC20 token from zkSync to Ethereum. +title: Withdraw ERC20 tokens from ZKsync +description: Learn how to create a script to withdraw any ERC20 token from ZKsync to Ethereum. --- -Withdrawing assets from Layer 2 (L2) back to Layer 1 (L1) is an essential procedure to retrieve your assets in zkSync. -This guide outlines how to withdraw ETH using the zkSync Javascript SDK, ensuring a successful transfer of assets to L1. -In zkSync, withdrawing involves burning tokens on L2 and unlocking the corresponding funds on the L1 bridge. +Withdrawing assets from Layer 2 (L2) back to Layer 1 (L1) is an essential procedure to retrieve your assets in ZKsync. +This guide outlines how to withdraw ETH using the ZKsync Javascript SDK, ensuring a successful transfer of assets to L1. +In ZKsync, withdrawing involves burning tokens on L2 and unlocking the corresponding funds on the L1 bridge. ## Prerequisites @@ -24,7 +24,7 @@ Withdrawing assets from L2 to L1 involves the following steps: unlocking the funds from the L1 bridge and sending them to the recipient. ::callout{icon="i-heroicons-exclamation-triangle"} -During the Alpha phase, **withdrawals in zkSync Era take 24 hours** for additional security. +During the Alpha phase, **withdrawals in ZKsync Era take 24 hours** for additional security. :: ## Setup Environment @@ -57,7 +57,7 @@ L1_RPC_ENDPOINT= ## Create the Withdrawal Script Create a new file `withdraw-erc20.ts` and insert the following code. -This script utilizes the `withdraw` method from the `Wallet` class of the zkSync Javascript SDK to withdraw ETH. +This script utilizes the `withdraw` method from the `Wallet` class of the ZKsync Javascript SDK to withdraw ETH. Adjust the `AMOUNT` and `TOKEN_ADDRESS` variable if necessary. #### withdraw-erc20.ts script @@ -72,7 +72,7 @@ dotenv.config(); // HTTP RPC endpoints const L1_RPC_ENDPOINT = process.env.L1_RPC_ENDPOINT || ""; // or an RPC endpoint from Infura/Chainstack/QuickNode/etc. -const L2_RPC_ENDPOINT = process.env.L2_RPC_ENDPOINT || "%%zk_testnet_rpc_url%%"; // or the zkSync Era mainnet +const L2_RPC_ENDPOINT = process.env.L2_RPC_ENDPOINT || "%%zk_testnet_rpc_url%%"; // or the ZKsync Era mainnet // ERC-20 Token address in L2 const TOKEN_ADDRESS = ""; @@ -143,5 +143,5 @@ Withdraw ERC-20 transaction sent 0x280a2168f464c93e8c56df3291076bbb6cff78ebdc30f ## Conclusion -By following this guide, you have successfully withdrawn ERC-20 token from L2 to L1 using the zkSync Javascript SDK. -This is a significant step towards managing your assets on the zkSync Era. +By following this guide, you have successfully withdrawn ERC-20 token from L2 to L1 using the ZKsync Javascript SDK. +This is a significant step towards managing your assets on the ZKsync Era. diff --git a/content/tutorials/how-to-withdraw-erc20/_dir.yml b/content/tutorials/how-to-withdraw-erc20/_dir.yml index 1fca4d6..abf71cc 100644 --- a/content/tutorials/how-to-withdraw-erc20/_dir.yml +++ b/content/tutorials/how-to-withdraw-erc20/_dir.yml @@ -1,18 +1,18 @@ -title: How to withdraw ERC20 tokens from zkSync +title: How to withdraw ERC20 tokens from ZKsync authors: - - name: MatterLabs + - name: Matter Labs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - hardhat - how-to - erc20 -summary: Learn how to withdraw ERC20 tokens zkSync. -description: This how-to guide explains how to create a script that withdraw any ERC20 token from zkSync to Ethereum. +summary: Learn how to withdraw ERC20 tokens ZKsync. +description: This how-to guide explains how to create a script that withdraw any ERC20 token from ZKsync to Ethereum. what_you_will_learn: - How L2 withdraw work - - How to withdraw ERC20 tokens to zkSync + - How to withdraw ERC20 tokens to ZKsync updated: 2024-05-09 tools: - zksync-ethers diff --git a/content/tutorials/how-to-withdraw-eth/10.index.md b/content/tutorials/how-to-withdraw-eth/10.index.md index 0bd82a7..c509630 100644 --- a/content/tutorials/how-to-withdraw-eth/10.index.md +++ b/content/tutorials/how-to-withdraw-eth/10.index.md @@ -1,11 +1,11 @@ --- -title: Withdraw Ether from zkSync -description: Learn how to create a script to withdraw Ether from zkSync to Ethereum. +title: Withdraw Ether from ZKsync +description: Learn how to create a script to withdraw Ether from ZKsync to Ethereum. --- -Withdrawing assets from Layer 2 (L2) back to Layer 1 (L1) is an essential procedure to retrieve your assets in zkSync. -This guide outlines how to withdraw ETH using the zkSync Javascript SDK, ensuring a successful transfer of assets to L1. -In zkSync, withdrawing involves burning tokens on L2 and unlocking the corresponding funds on the L1 bridge. +Withdrawing assets from Layer 2 (L2) back to Layer 1 (L1) is an essential procedure to retrieve your assets in ZKsync. +This guide outlines how to withdraw ETH using the ZKsync Javascript SDK, ensuring a successful transfer of assets to L1. +In ZKsync, withdrawing involves burning tokens on L2 and unlocking the corresponding funds on the L1 bridge. ## Prerequisites @@ -24,7 +24,7 @@ Withdrawing assets from L2 to L1 involves the following steps: unlocking the funds from the L1 bridge and sending them to the recipient. ::callout{icon="i-heroicons-exclamation-triangle"} -During the Alpha phase, **withdrawals in zkSync Era take 24 hours** for additional security. +During the Alpha phase, **withdrawals in ZKsync Era take 24 hours** for additional security. :: ## Setup Environment @@ -57,7 +57,7 @@ L1_RPC_ENDPOINT= ## Create the Withdrawal Script Create a new file `withdraw.ts` and insert the following code. -This script utilizes the `withdraw` method from the `Wallet` class of the zkSync Javascript SDK to withdraw ETH. +This script utilizes the `withdraw` method from the `Wallet` class of the ZKsync Javascript SDK to withdraw ETH. Adjust the `AMOUNT` variable if necessary. #### withdraw.ts script @@ -72,7 +72,7 @@ dotenv.config(); // HTTP RPC endpoints const L1_RPC_ENDPOINT = process.env.L1_RPC_ENDPOINT || ""; // or an RPC endpoint from Infura/Chainstack/QuickNode/etc. -const L2_RPC_ENDPOINT = process.env.L2_RPC_ENDPOINT || "%%zk_testnet_rpc_url%%"; // or the zkSync Era mainnet +const L2_RPC_ENDPOINT = process.env.L2_RPC_ENDPOINT || "%%zk_testnet_rpc_url%%"; // or the ZKsync Era mainnet // Wallet const WALLET_PRIV_KEY = process.env.WALLET_PRIV_KEY || ""; @@ -142,5 +142,5 @@ Withdraw transaction sent 0x4905176d42b4c3b4ab10f611e688b2d849e761493f4583119b7c ## Conclusion -By following this guide, you have successfully withdrawn ETH from L2 to L1 using the zkSync Javascript SDK. -This is a significant step towards managing your assets on the zkSync Era. +By following this guide, you have successfully withdrawn ETH from L2 to L1 using the ZKsync Javascript SDK. +This is a significant step towards managing your assets on the ZKsync Era. diff --git a/content/tutorials/how-to-withdraw-eth/_dir.yml b/content/tutorials/how-to-withdraw-eth/_dir.yml index 3e687da..6ffa161 100644 --- a/content/tutorials/how-to-withdraw-eth/_dir.yml +++ b/content/tutorials/how-to-withdraw-eth/_dir.yml @@ -1,18 +1,18 @@ -title: How to withdraw Ether from zkSync +title: How to withdraw Ether from ZKsync authors: - - name: MatterLabs + - name: Matter Labs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - hardhat - how-to - Ether -summary: Learn how to withdraw Ether from zkSync. -description: This how-to guide explains how to create a script that withdraws Ether from zkSync. +summary: Learn how to withdraw Ether from ZKsync. +description: This how-to guide explains how to create a script that withdraws Ether from ZKsync. what_you_will_learn: - How L2 withdrawals work - - How to withdraw Ether from zkSync + - How to withdraw Ether from ZKsync updated: 2024-05-09 tools: - zksync-ethers diff --git a/content/tutorials/native-aa-multisig/10.index.md b/content/tutorials/native-aa-multisig/10.index.md index d61cfb5..07aea18 100644 --- a/content/tutorials/native-aa-multisig/10.index.md +++ b/content/tutorials/native-aa-multisig/10.index.md @@ -37,7 +37,7 @@ Atlas is a smart contract IDE that lets you write, deploy, and interact with con npx zksync-cli create custom-aa-tutorial --template hardhat_solidity ``` - This creates a new zkSync Era project called `custom-aa-tutorial` with a few example contracts. + This creates a new ZKsync Era project called `custom-aa-tutorial` with a few example contracts. 1. Navigate into the project directory: @@ -53,7 +53,7 @@ Atlas is a smart contract IDE that lets you write, deploy, and interact with con rm -rf ./deploy/* ``` -1. Add the zkSync and OpenZeppelin contract libraries: +1. Add the ZKsync and OpenZeppelin contract libraries: ```sh yarn add -D @matterlabs/zksync-contracts @openzeppelin/contracts@4.9.5 @@ -378,7 +378,7 @@ case, since it behaves in the same way as your storage, it just happens to be in To call the `NONCE_HOLDER_SYSTEM_CONTRACT`, we add the following import: ```solidity -// Access zkSync system contracts for nonce validation via NONCE_HOLDER_SYSTEM_CONTRACT +// Access ZKsync system contracts for nonce validation via NONCE_HOLDER_SYSTEM_CONTRACT import "@matterlabs/zksync-contracts/l2/system-contracts/Constants.sol"; ``` @@ -550,7 +550,7 @@ import "@openzeppelin/contracts/interfaces/IERC1271.sol"; // Used for signature validation import "@openzeppelin/contracts/utils/cryptography/ECDSA.sol"; -// Access zkSync system contracts for nonce validation via NONCE_HOLDER_SYSTEM_CONTRACT +// Access ZKsync system contracts for nonce validation via NONCE_HOLDER_SYSTEM_CONTRACT import "@matterlabs/zksync-contracts/l2/system-contracts/Constants.sol"; // to call non-view function of system contracts import "@matterlabs/zksync-contracts/l2/system-contracts/libraries/SystemContractsCaller.sol"; @@ -845,7 +845,7 @@ contract TwoUserMultisig is IAccount, IERC1271 { } ``` -It's worth remembering that, on zkSync Era, [contract deployments](https://docs.zksync.io/build/developer-reference/ethereum-differences/contract-deployment) +It's worth remembering that, on ZKsync Era, [contract deployments](https://docs.zksync.io/build/developer-reference/ethereum-differences/contract-deployment) are not done via bytecode, but via bytecode hash. The bytecode itself is passed to the operator via the `factoryDeps` field. Note that the `_aaBytecodeHash` must be formed in the following manner: @@ -858,7 +858,7 @@ This functionality is built into the SDK. ## Deploy the Factory ::callout{icon="i-heroicons-light-bulb"} -Make sure you deposit funds on zkSync Era using [one of the available bridges](https://zksync.io/explore#bridges) before running the deployment script. +Make sure you deposit funds on ZKsync Era using [one of the available bridges](https://zksync.io/explore#bridges) before running the deployment script. :: 1. In the `deploy` folder, create the file `deploy-factory.ts` and copy/paste the following code, replacing `` with your private key. @@ -914,7 +914,7 @@ Note that the address will be different for each run. Now, let's deploy an account and use it to initiate a new transaction. ::callout{icon="i-heroicons-exclamation-triangle"} -This section assumes you have an EOA account with sufficient funds on zkSync Era to deploy a smart contract account. +This section assumes you have an EOA account with sufficient funds on ZKsync Era to deploy a smart contract account. :: In the `deploy` folder, create a file called `deploy-multisig.ts`. @@ -963,11 +963,11 @@ export default async function (hre: HardhatRuntimeEnvironment) { ``` ::callout{icon="i-heroicons-light-bulb"} -zkSync has different address derivation rules from Ethereum. +ZKsync has different address derivation rules from Ethereum. Always use the [`createAddress`](https://docs.zksync.io/sdk/ethers/v6/utils#createaddress) and [`create2Address`](https://docs.zksync.io/sdk/ethers/v6/utils#create2address) utility functions of the `zksync-ethers` SDK. -Read the documentation for more information on [address derivation differences between Ethereum and zkSync](https://docs.zksync.io/build/developer-reference/ethereum-differences/evm-instructions#address-derivation). +Read the documentation for more information on [address derivation differences between Ethereum and ZKsync](https://docs.zksync.io/build/developer-reference/ethereum-differences/evm-instructions#address-derivation). :: ### Start a Transaction from the Account @@ -1203,9 +1203,9 @@ so it has enough funds to pay for the transaction fees. ## Learn More -- To learn more about L1->L2 interaction on zkSync, check out the +- To learn more about L1->L2 interaction on ZKsync, check out the [documentation](https://docs.zksync.io/build/developer-reference/l1-l2-interoperability). - To learn more about the `zksync-ethers` SDK, check out its [documentation](https://docs.zksync.io/sdk/ethers/v6/getting-started). -- To learn more about the zkSync hardhat plugins, check out their +- To learn more about the ZKsync hardhat plugins, check out their [documentation](https://docs.zksync.io/build/tooling/hardhat/getting-started). diff --git a/content/tutorials/native-aa-multisig/_dir.yml b/content/tutorials/native-aa-multisig/_dir.yml index e1125b2..dabb9d8 100644 --- a/content/tutorials/native-aa-multisig/_dir.yml +++ b/content/tutorials/native-aa-multisig/_dir.yml @@ -1,9 +1,9 @@ title: Native multisig smart account authors: - - name: MatterLabs + - name: Matter Labs url: https://matter-labs.io avatar: https://avatars.githubusercontent.com/u/42489169?s=200&v=4 -github_repo: https://github.com/zkSync-Community-Hub +github_repo: https://github.com/ZKsync-Community-Hub tags: - account abstraction - smart contracts diff --git a/cspell-config/cspell-zksync.txt b/cspell-config/cspell-zksync.txt index ca3c3e8..61c5b71 100644 --- a/cspell-config/cspell-zksync.txt +++ b/cspell-config/cspell-zksync.txt @@ -11,9 +11,9 @@ zkforge zkout zksolc zkstack -zkSync +!zkSync zksync -!ZKsync +ZKsync zksync-cli zkvyper diff --git a/pages/index.vue b/pages/index.vue index db58534..62dedc3 100644 --- a/pages/index.vue +++ b/pages/index.vue @@ -23,7 +23,7 @@ useSeoMeta({ diff --git a/public/logos/zksync-icon.svg b/public/logos/zksync-icon.svg index c3564cd..0b25b7b 100644 --- a/public/logos/zksync-icon.svg +++ b/public/logos/zksync-icon.svg @@ -1 +1 @@ - \ No newline at end of file + diff --git a/template/tutorial-template/10.index.md b/template/tutorial-template/10.index.md index 36f755b..efb9fbf 100644 --- a/template/tutorial-template/10.index.md +++ b/template/tutorial-template/10.index.md @@ -7,12 +7,12 @@ This tutorial shows you how to add a new tutorial to the Code Community project! ## Prerequisites -- [Fork this project on GitHub](https://github.com/zkSync-Community-Hub/community-code) and create a branch to track your work. -- Make sure you have set up your project following the [README](https://github.com/zkSync-Community-Hub/community-code/blob/main/README.md). +- [Fork this project on GitHub](https://github.com/ZKsync-Community-Hub/community-code) and create a branch to track your work. +- Make sure you have set up your project following the [README](https://github.com/ZKsync-Community-Hub/community-code/blob/main/README.md). - Spend some time getting to know the available tools that are available. - [Nuxt Content](https://content.nuxt.com/) - [Nuxt UI & Nuxt UI Pro](https://ui.nuxt.com/) - - and more in our [CONTRIBUTING](https://github.com/zkSync-Community-Hub/community-code/blob/main/CONTRIBUTING.md) + - and more in our [CONTRIBUTING](https://github.com/ZKsync-Community-Hub/community-code/blob/main/CONTRIBUTING.md) ## Create a new tutorial @@ -51,7 +51,7 @@ Please avoid writing custom html and css in your tutorials. You can use Nuxt UI components in your markdown file! Component syntax however is a little different in markdown. Learn more in the Contributing page for -[Using UI components](https://github.com/zkSync-Community-Hub/community-code/blob/main/CONTRIBUTING.md#using-ui-components). +[Using UI components](https://github.com/ZKsync-Community-Hub/community-code/blob/main/CONTRIBUTING.md#using-ui-components). ::callout{icon="i-heroicons-light-bulb"} Want to call something out? Use the callout component!