Create an account


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Tut] Polygon for Developers – A Simple Guide with Video

#1
Polygon for Developers – A Simple Guide with Video

<div><div class="kk-star-ratings kksr-valign-top kksr-align-left " data-payload="{&quot;align&quot;:&quot;left&quot;,&quot;id&quot;:&quot;436140&quot;,&quot;slug&quot;:&quot;default&quot;,&quot;valign&quot;:&quot;top&quot;,&quot;reference&quot;:&quot;auto&quot;,&quot;count&quot;:&quot;1&quot;,&quot;readonly&quot;:&quot;&quot;,&quot;score&quot;:&quot;5&quot;,&quot;best&quot;:&quot;5&quot;,&quot;gap&quot;:&quot;5&quot;,&quot;greet&quot;:&quot;Rate this post&quot;,&quot;legend&quot;:&quot;5\/5 - (1 vote)&quot;,&quot;size&quot;:&quot;24&quot;,&quot;width&quot;:&quot;142.5&quot;,&quot;_legend&quot;:&quot;{score}\/{best} - ({count} {votes})&quot;}">
<div class="kksr-stars">
<div class="kksr-stars-inactive">
<div class="kksr-star" data-star="1" style="padding-right: 5px">
<div class="kksr-icon" style="width: 24px; height: 24px;"></div>
</p></div>
<div class="kksr-star" data-star="2" style="padding-right: 5px">
<div class="kksr-icon" style="width: 24px; height: 24px;"></div>
</p></div>
<div class="kksr-star" data-star="3" style="padding-right: 5px">
<div class="kksr-icon" style="width: 24px; height: 24px;"></div>
</p></div>
<div class="kksr-star" data-star="4" style="padding-right: 5px">
<div class="kksr-icon" style="width: 24px; height: 24px;"></div>
</p></div>
<div class="kksr-star" data-star="5" style="padding-right: 5px">
<div class="kksr-icon" style="width: 24px; height: 24px;"></div>
</p></div>
</p></div>
<div class="kksr-stars-active" style="width: 142.5px;">
<div class="kksr-star" style="padding-right: 5px">
<div class="kksr-icon" style="width: 24px; height: 24px;"></div>
</p></div>
<div class="kksr-star" style="padding-right: 5px">
<div class="kksr-icon" style="width: 24px; height: 24px;"></div>
</p></div>
<div class="kksr-star" style="padding-right: 5px">
<div class="kksr-icon" style="width: 24px; height: 24px;"></div>
</p></div>
<div class="kksr-star" style="padding-right: 5px">
<div class="kksr-icon" style="width: 24px; height: 24px;"></div>
</p></div>
<div class="kksr-star" style="padding-right: 5px">
<div class="kksr-icon" style="width: 24px; height: 24px;"></div>
</p></div>
</p></div>
</div>
<div class="kksr-legend"> 5/5 – (1 vote) </div>
</div>
<figure class="wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio">
<div class="wp-block-embed__wrapper">
<iframe loading="lazy" title="Polygon Quickstart for Developers" width="780" height="439" src="https://www.youtube.com/embed/HnMCQAyUDVk?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
</div>
</figure>
<p>What are Polygon and MATIC all about and why is another blockchain needed? You will find answers to these questions in this article. </p>
<p>The article starts with problems plaguing Ethereum, workable solutions to the problem, and then dives into more details of the Polygon network, its history, tokenomics, and an overview of the Polygon SDK.</p>
<h2><a id="_2t0x7ca76uc4"></a>Ethereum Scaling Problems</h2>
<p>To date, <a href="https://blog.finxter.com/ethereum-top-10-articles-to-get-started/" data-type="post" data-id="53284" target="_blank" rel="noreferrer noopener">Ethereum</a> remains the most widely adopted and actively used blockchain in the current scenario. </p>
<p>It gained popularity because of its offering of <a href="https://blog.finxter.com/smart-contracts-and-evm/" data-type="post" data-id="92507" target="_blank" rel="noreferrer noopener">smart contract</a> functionality, variety of tools, ecosystem, and sizable community support. </p>
<p>However, using Ethereum comes at a price because of its high <a href="https://blog.finxter.com/introduction-to-ethereums-gas-in-solidity-development/" data-type="post" data-id="37644" target="_blank" rel="noreferrer noopener">gas fees</a>, network clogging because of many users, and lower transactions per second (approximately ~30 tps).</p>
<h3><a id="_9ynmwg6bn1kd"></a>Ethereum TPS</h3>
<p>Why do transactions on Ethereum (or also <a rel="noreferrer noopener" href="https://blog.finxter.com/how-to-value-bitcoin/" data-type="post" data-id="31351" target="_blank">Bitcoin</a>) take so long?</p>
<p>The answer is in the <a href="https://blog.finxter.com/how-much-does-a-blockchain-engineer-make/" data-type="post" data-id="161686" target="_blank" rel="noreferrer noopener">blockchain</a>‘s structure. In these blockchains, before we approve a transaction, it must pass through various stages – queue in the transaction pools, mining, distribution, and validation. </p>
<p>Ethereum, also called layer-1 or base layer, must handle all the activities before the transaction gets included in the block and the block makes it to the chain. </p>
<p>Inevitably, there are delays in processing which affect the user experience and scalability at Ethereum or layer-1. Compare this with centralized systems such as Paypal or Visa with a TPS value as high as ~24,000.</p>
<h2><a id="_90ckj6njjy6v"></a>Solutions to Scaling</h2>
<p>You may wonder, “<em>why Ethereum or layer-1 itself can’t be scaled ?”</em>.</p>
<p>First, the problem is that sophistication levels introduced at layer-1 to solve scaling problems mean writing more code at this layer, resulting in more time to bring improvements, new features to Ethereum, and countless discussions. </p>
<p>Second, more code at layer-1 means compromising security for scalability.</p>
<p>Scaling problems such as the one described above have multiple solutions. </p>
<p>As this tutorial focuses mostly on <a href="https://polygon.technology/" data-type="URL" data-id="https://polygon.technology/" target="_blank" rel="noreferrer noopener">Polygon</a>, the other scaling solutions are mentioned here only for reference. We can divide the scaling solutions mainly as On-Chain and Off-Chain and further classified as in the below fig.</p>
<div class="wp-block-image">
<figure class="aligncenter size-full"><img loading="lazy" width="621" height="361" src="https://blog.finxter.com/wp-content/uploads/2022/06/image-164.png" alt="" class="wp-image-436147" srcset="https://blog.finxter.com/wp-content/uploads/2022/06/image-164.png 621w, https://blog.finxter.com/wp-content/uplo...00x174.png 300w" sizes="(max-width: 621px) 100vw, 621px" /><figcaption><strong>Fig:</strong> Scaling Ethereum</figcaption></figure>
</div>
<p>Most of the time, the names layer-2 or side chains are applied interchangeably, but there is a difference. While layer-2 inherits the <a href="https://blog.finxter.com/tx-origin-phishing-attack-smart-contract-security-series-part-4/" data-type="post" data-id="295985" target="_blank" rel="noreferrer noopener">security</a> of the Ethereum network (mainnet), sidechains rely on their own security model.</p>
<p>In the next section, we start with Polygon, a sidechain solution (blockchain that runs parallel to the mainnet Ethereum), and how it solves the Ethereum scaling problem.</p>
<h2><a id="_dl81mey3ye5d"></a>Polygon Origins</h2>
<p>Originally known as <em>Matic networks</em>, it was started in 2017, in India by <em>Anurag Arjun, Sandeep Nailwal, Jaynti Kanani,</em> and <em>Mihailo Bjelic.</em> </p>
<p>Initially, it offered two solutions to the Ethereum scaling problem.</p>
<ul>
<li><a href="https://blog.finxter.com/common-consensus-mechanisms-in-blockchains/" data-type="post" data-id="70966" target="_blank" rel="noreferrer noopener">PoS</a> sidechain, a proof of stake Ethereum sidechain</li>
<li>Plasma chain</li>
</ul>
<p>In 2021, it was renamed or rebranded as <strong><em>Polygon</em></strong>. </p>
<p>Polygon’s goal has evolved from offering Ethereum network layer-2 to developing the entire blockchain network architecture for developers, as seen by the name change. </p>
<p>Polygon is presently working on a roadmap for connecting numerous layer-2 solutions forming a multi-layer-2 blockchain network that can coexist with the Ethereum network.</p>
<p>The existing Polygon solutions<strong> PoS sidechain</strong> and the <strong>Plasma chain</strong> will continue to exist and will be an important part of the growing Polygon multichain system.</p>
<h3><a id="_ctf3su5m0lkh"></a>Tokenomics and dApps</h3>
<p>MATIC is the token name offered by the Polygon Network. Polygon MATIC began as a testnet in October 2017 and then transitioned to mainnet later that year. </p>
<p>During its maiden offering in April 2019, the company raised $5.6 million in ETH by selling 1.9 billion MATIC tokens over the course of 20 days. They formed the Matic Network in 2020, and Matic changed its name to <strong><em>Polygon Network</em></strong> in February 2021.</p>
<p><a href="https://aave.com/" data-type="URL" data-id="https://aave.com/">AAVE</a> debuted on the platform in April 2021, enhancing the Polygon network’s value. Other famous <a href="https://blog.finxter.com/top-10-solidity-tutorials/" data-type="post" data-id="262867" target="_blank" rel="noreferrer noopener">dApps</a> (<a href="https://blog.finxter.com/top-defi-articles/" data-type="post" data-id="395129" target="_blank" rel="noreferrer noopener">Defi</a>, <a href="https://blog.finxter.com/nft-101/" data-type="post" data-id="38160">N</a><a href="https://blog.finxter.com/nft-101/" data-type="post" data-id="38160" target="_blank" rel="noreferrer noopener">F</a><a href="https://blog.finxter.com/nft-101/" data-type="post" data-id="38160">Ts</a>, and Dex) launched on Polygon include Quickswap, KogeFarm, Aavegotchi, etc.</p>
<h2><a id="_okumkm34g8lc"></a>Polygon SDK Overview</h2>
<p>Polygon is more of a protocol than a single solution to scaling, and up to this point, the Polygon framework aims to support two types of Ethereum compatible solutions: <strong>Secured chains</strong> and <strong>Stand-alone chains.</strong></p>
<h3>Secured Chains</h3>
<p><strong>Secured chains </strong>are chains that have the potential to internalize, make use of the existing security of the Ethereum network. </p>
<p>It allows developers to use Polygon’s scalability while still employing the Ethereum network’s security. As secured chains don’t have their own security model, they offer better security and lesser flexibility. </p>
<p>Secured chains are suitable for security focussed projects and startups. An example of a secured chain is <strong><em>Rollups</em></strong>.</p>
<h3>Stand-Alone Chains</h3>
<p><strong>Stand-alone</strong> chains fully define their own security model of consensus mechanisms such as Proof Of Stake (PoS) and Delegated Proof Of Stake(dPoS). </p>
<p>They have their own miner or validator pools. </p>
<p>They offer better flexibility and independence but lesser security because of their own security mechanism in place. </p>
<p>Stand-alone chains are suitable for enterprise blockchains and projects needing more flexibility than security. An example of Stand-alone chains is <strong><em>sidechains</em></strong>.</p>
<p>The Polygon SDK offering can be summarized with the picture below:</p>
<div class="wp-block-image">
<figure class="aligncenter size-full"><img loading="lazy" width="536" height="503" src="https://blog.finxter.com/wp-content/uploads/2022/06/image-165.png" alt="" class="wp-image-436153" srcset="https://blog.finxter.com/wp-content/uploads/2022/06/image-165.png 536w, https://blog.finxter.com/wp-content/uplo...00x282.png 300w" sizes="(max-width: 536px) 100vw, 536px" /><figcaption><strong>Fig: </strong>Polygon Multichain support (credit: <a href="https://blog.polygon.technology/">Polygon</a>)</figcaption></figure>
</div>
<h2>Dominance Over Other Layer-2 Blockchain Solutions</h2>
<p>Polygon offers several advantages over other blockchain ecosystems for layer-2 scaling like Polkadot (DOT), Avalanche (AVAX), and Cosmos (ATOM).</p>
<ul>
<li>Polygon provides developers a fully customizable tech stack, with a user experience akin to Ethereum.</li>
<li>Polygon can use the full capacity of the Ethereum network thanks to the multi-chain technology, which allows it to do so without losing throughput or security.</li>
<li>Polygon provides blockchain speed-up solutions, allowing for faster transactions and reduced gas rates than the Ethereum mainnet. Polygon also plans to provide developers with tools for creating Ethereum-compatible blockchain networks.</li>
</ul>
<p>Polygon is thus critical for <a rel="noreferrer noopener" href="https://blog.finxter.com/top-crypto-jobs-for-coders-in-2023/" data-type="post" data-id="405444" target="_blank">developers</a> and small-to-medium-sized enterprises concerned with Ethereum’s network congestion. As a long-term scaling solution, Polygon can provide a wide range of utilities for developers. Some people believe that this potential gives the MATIC token a one-of-a-kind value proposition.</p>
<h2><a id="_58sfzom2i4l"></a>Polygon For a User</h2>
<p>Users who interact with Polygon frequently only view the blockchain as a whole, and the underlying architecture is unimportant to them. </p>
<p>Polygon allows any Ethereum-compatible web wallet, such as <a href="https://blog.finxter.com/metamask-simple-tutorial/" data-type="post" data-id="38157" target="_blank" rel="noreferrer noopener">Metamask</a>, to connect, acquire funds (MATIC), and interact with dApps deployed across the network. </p>
<p>For a long time, <a href="https://blog.finxter.com/creating-an-nft-marketplace-with-solidity-and-javascript/" data-type="post" data-id="170312" target="_blank" rel="noreferrer noopener">OpenSea</a> has permitted the minting and <a href="https://blog.finxter.com/crypto-trading-bot-developer-income-and-opportunity/" data-type="post" data-id="175039" target="_blank" rel="noreferrer noopener">trading</a> of NFTs on Polygon.</p>
<h2><a id="_9f4v39iqoaum"></a>Conclusion</h2>
<p>This article discussed the Ethereum scalability issue and how the Polygon sidechain network can help solve the base-layer or layer-1 issues, as well as an overview of the Polygon SDK framework and how it compares to alternative solutions at this time.</p>
<p>The next posts will explore more on the Polygon networks and hands-on developing dApps on Polygon.</p>
<h2>Nerd Humor</h2>
<div class="wp-block-image">
<figure class="aligncenter size-full"><img loading="lazy" width="733" height="913" src="https://blog.finxter.com/wp-content/uploads/2022/06/image-72.png" alt="" class="wp-image-410345" srcset="https://blog.finxter.com/wp-content/uploads/2022/06/image-72.png 733w, https://blog.finxter.com/wp-content/uplo...41x300.png 241w" sizes="(max-width: 733px) 100vw, 733px" /><figcaption><em>Oh yeah, I didn’t even know they renamed it the Willis Tower in 2009, because I know a normal amount about skyscrapers.</em> — <a rel="noreferrer noopener" href="https://imgs.xkcd.com/comics/or_whatever_2x.png" data-type="URL" data-id="https://imgs.xkcd.com/comics/or_whatever_2x.png" target="_blank">xkcd</a> (source)</figcaption></figure>
</div>
</div>


https://www.sickgaming.net/blog/2022/06/...ith-video/
Reply



Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum software by © MyBB Theme © iAndrew 2016