<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Niharika Singh on Medium]]></title>
        <description><![CDATA[Stories by Niharika Singh on Medium]]></description>
        <link>https://medium.com/@niharika3297?source=rss-44716129d0a2------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*NT7-5YxD7Jo513Fu.jpg</url>
            <title>Stories by Niharika Singh on Medium</title>
            <link>https://medium.com/@niharika3297?source=rss-44716129d0a2------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 14 Nov 2026 02:28:03 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@niharika3297/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[How to Improve YouTube with LLMs]]></title>
            <link>https://niharika3297.medium.com/how-to-improve-youtube-with-llms-17c9e8d2902b?source=rss-44716129d0a2------2</link>
            <guid isPermaLink="false">https://medium.com/p/17c9e8d2902b</guid>
            <category><![CDATA[python]]></category>
            <category><![CDATA[tutorial]]></category>
            <category><![CDATA[nlp]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[technology]]></category>
            <dc:creator><![CDATA[Niharika Singh]]></dc:creator>
            <pubDate>Wed, 13 Sep 2023 14:18:33 GMT</pubDate>
            <atom:updated>2023-09-13T14:18:33.794Z</atom:updated>
            <content:encoded><![CDATA[<h4>Learn how to create a video summarizer using Whisper from OpenAI and BART from Meta on Hugging Face</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7Wg4DKuQrb5UW3jIyY01nQ.png" /></figure><p>Originally posted on: <a href="https://writings.niharika.me/how-to-improve-youtube-with-llms">https://writings.niharika.me/how-to-improve-youtube-with-llms</a></p><p><em>Last update: Wednesday, September 13, 2023</em></p><p>The way humans interact with technology has come a long way. In the early days of computing, users had to input commands using punch cards. At this point, if you have to pause and consciously think about “punch cards,” then I proved my point quite effectively;</p><blockquote><em>Humans have indeed come a long long way in how we interact and navigate the digital world.</em></blockquote><p>The story of the metaverse is shaping up rapidly becoming increasingly natural and intuitive. We are leveraging touch, voice, gestures, and probably direct brain connections in the near future.</p><p>Lightning-fast advances in Natural Language Processing (NLP) have enabled us to engineer even better user experiences. Just when you think there is probably no more room left for optimization, there is. NLP effectively makes machines understand and generate human language. This creates a significant impact on how we communicate with technology.</p><p>🎯 The purpose of this blog is to explore how YouTube can be improved by capitalizing on the latest groundbreaking advancements in LLMs and to create a video summarizer using Whisper from OpenAI and BART from Meta.</p><h3>How would I improve YouTube</h3><p>As a product manager, it is key for me to identify challenge areas in a product and strategically devise solutions that not only address these issues but also align with the larger product vision and goals. The product in question here is YouTube.</p><h3>User groups</h3><p>I don’t think I need to define what YouTube is. So I can skip this part and get to defining the key user segments of YouTube. Broadly speaking, they fall into two categories:</p><ol><li>Creators</li><li>Consumers</li></ol><p>For the purpose of this blog, I will focus on the consumers. Without consumers, creators lose their value. Therefore, it is key to enhance the consumer’s experience at every step of the way.</p><h3>Potential pain points / challenges</h3><ul><li><strong>Misleading thumbnails and titles</strong>: Clickbaits. Extremely frustrating for viewers seeking relevant content.</li><li><strong>Inappropriate content</strong>: Despite YouTube’s content moderation efforts, viewers may come across content containing offensive, harmful, or inappropriate content.</li><li><strong>Content duplication</strong>: What is more annoying than different creators uploading the same video repeatedly cluttering the search results and making it difficult to find the original video.</li><li><strong>Limited content discovery</strong>: If YouTube’s recommendation algorithm doesn’t align with the viewer’s interest, it can be very difficult to discover new and relevant content.</li><li><strong>Limited content accessibility</strong>: Imagine not being able to understand a video just because you don’t know the language it is in. Most of the content by top channels on YouTube is in <a href="https://www.twinword.com/blog/features-of-top-250-youtube-channels/">English</a>.</li></ul><h3>Ideas that may help improve UX of consumers</h3><ul><li><strong>Natural language interaction with the video</strong>: Viewers can read the text summary of the video before jumping into watching a video. Let’s say the video is a 50-minute-long panel discussion. This improvement will also save a lot of time of the viewer, helping them make a more informed choice about the content they will consume. The user can also ask questions and get answers in text without necessarily watching the video.</li><li><strong>Detect and flag inappropriate + duplicate content</strong></li><li><strong>Enhanced recommendation algorithms</strong></li><li><strong>Multilingual support and accessibility</strong>: Viewers can view the video in any language they like in the same voice as the narrator. This will enhance the reach of every video bringing down the language barriers.</li></ul><h3>Time to create a video summarizer</h3><p>Personally, for me clickbaits are annoying and sometimes before committing to watching a long video, I’d like to judge the video based on a text summary. At the moment, I rely on comments on the videos. However, there are instances when there are not many helpful comments or maybe commenting had been turned off.</p><p>I will address this painpoint by leveraging LLMs that will generate a text summary of any YouTube video I give as an input.</p><h3>In a nutshell…</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*UGDHjVfsB5AnlCE2" /></figure><h3>Web interface</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*WSK1e_oORJKHXevO" /></figure><p>The user will enter the link to the YouTube video and click on ‘Summarize Video’ button.</p><p>Let me enter this YouTube video and see what comes out.</p><p><a href="https://www.youtube.com/watch?v=SHw5iZ0tI48">https://www.youtube.com/watch?v=SHw5iZ0tI48</a></p><p>Here’s the output:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*l8dJznBbqZ-tzoVn" /></figure><p><strong>Summary:</strong></p><p>“The original iPod was a pioneer in terms of the simple design and easy-to-use functionality. Apple credited the idea of the iPod to an obscure man by the name of Ken Kramer. The rise of the MP3 file format caused a lot of commotion in the music industry.”</p><p>Quite good, no?</p><p>Here’s the python script I’m using to do this <em>magic:</em></p><pre>import pytube<br>import requests<br>import os<br>from dotenv import find_dotenv, load_dotenv<br>import openai<br>import streamlit as st<br><br>st.title(&#39;YouTube Video Summarization&#39;)<br><br>load_dotenv(find_dotenv())<br>openai.api_key = os.getenv(&quot;OPENAI_API_KEY&quot;)<br>HUGGINGFACEHUB_API_TOKEN=os.getenv(&quot;HUGGINGFACE_API_TOKEN&quot;)<br><br># Extract audio from YouTube<br>def get_audio(video_url):<br>    # Create a PyTube object for the video.<br>    youtube_video = pytube.YouTube(video_url)<br>    # Get the audio stream from the video.<br>    audio_stream = youtube_video.streams.filter(only_audio=True)<br>    # Get title<br>    st.write(&quot;Now summarizing: &quot;, youtube_video.streams[0].title)<br>    # Download the audio stream to a file.<br>    audio_stream[0].download(output_path=&quot;audios&quot;, filename=&quot;audio.mp3&quot;)<br><br># Audio to text<br>def get_text(filename):<br>    audio_file= open(filename, &quot;rb&quot;)<br>    transcript = openai.Audio.transcribe(&quot;whisper-1&quot;, audio_file)<br>    return transcript<br><br># Summarize<br>def summarize(transcript):<br>    API_URL = &quot;https://api-inference.huggingface.co/models/facebook/bart-large-cnn&quot;<br>    headers = {&quot;Authorization&quot;: f&quot;Bearer {HUGGINGFACEHUB_API_TOKEN}&quot;}<br>    payload = {<br>        &quot;inputs&quot;: transcript<br>    }<br>    response = requests.post(API_URL, headers=headers, json=payload)<br>    return response.json()<br><br>youtube_link = st.text_input(&#39;YouTube Video:&#39;, &#39;Enter URL here&#39;)<br>def process_input(youtube_link):<br>    get_audio(youtube_link)<br>    video_text = get_text(&quot;audios/audio.mp3&quot;)<br>    video_text = video_text.text<br>    summary = summarize(video_text)<br>    return summary[0]<br><br># Create a button to trigger the function<br>if st.button(&quot;Summarize Video&quot;):<br>    result = process_input(youtube_link)<br>    st.write(&quot;Summary&quot;, result)</pre><h3>Circling back</h3><p>Injecting LLMs into YouTube to enhance the UX and revolutionize the way we engage with videos on literally any platform is beyond awesome.</p><p>By providing video summaries, improving search and discovery, and enhancing accessibility and convenience, YouTube can become an even more user-friendly and informative platform.</p><p>As a product manager, I believe that exploring these possibilities and addressing the challenges will lead to a more enriched YouTube experience for everyone. It’s time to harness the power of LLMs and take YouTube to the next level of user satisfaction and engagement.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=17c9e8d2902b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Ethereum Layer 2: Explained]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://niharika3297.medium.com/ethereum-layer-2-explained-f7d0a3adecdb?source=rss-44716129d0a2------2"><img src="https://cdn-images-1.medium.com/max/1200/1*EjBxG_XTkaCea3EzS7ri4w.jpeg" width="1200"></a></p><p class="medium-feed-snippet">If you are an active member of the Ethereum community, then you will likely have heard catchphrases like &#x2018;going bankless&#x2019;, &#x2018;banking the&#x2026;</p><p class="medium-feed-link"><a href="https://niharika3297.medium.com/ethereum-layer-2-explained-f7d0a3adecdb?source=rss-44716129d0a2------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://niharika3297.medium.com/ethereum-layer-2-explained-f7d0a3adecdb?source=rss-44716129d0a2------2</link>
            <guid isPermaLink="false">https://medium.com/p/f7d0a3adecdb</guid>
            <category><![CDATA[ethereum]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[blockchain]]></category>
            <category><![CDATA[bitcoin]]></category>
            <category><![CDATA[scalability]]></category>
            <dc:creator><![CDATA[Niharika Singh]]></dc:creator>
            <pubDate>Sat, 15 May 2021 17:09:09 GMT</pubDate>
            <atom:updated>2021-05-15T17:09:09.782Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[How To Display Voting Results from Blockchain On UI]]></title>
            <link>https://medium.com/coinmonks/how-to-display-voting-results-from-blockchain-on-ui-6026c4b497cd?source=rss-44716129d0a2------2</link>
            <guid isPermaLink="false">https://medium.com/p/6026c4b497cd</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[dapps]]></category>
            <category><![CDATA[ethereum]]></category>
            <category><![CDATA[blockchain-technology]]></category>
            <category><![CDATA[technology]]></category>
            <dc:creator><![CDATA[Niharika Singh]]></dc:creator>
            <pubDate>Wed, 08 Jul 2020 15:56:06 GMT</pubDate>
            <atom:updated>2020-08-15T14:29:32.278Z</atom:updated>
            <content:encoded><![CDATA[<h4><em>This article is a part of a series called Corporate Governance on Blockchain.</em></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*6vzQ10vwAzmcRcHI7_ue-g.png" /></figure><p><a href="https://www.trycrypto.com/blog/how-blockchain-could-change-corporate-governance-for-the-better">Part 1</a> of the series outlines the potential applications of blockchain in corporate governance and walks through how to set up your project to follow this series. <a href="https://www.trycrypto.com/blog/part-2-voting-smart-contract">Part 2</a> outlines the entire business logic of the shareholder voting smart contract and includes best practices for smart contract development.</p><p>In <a href="https://www.trycrypto.com/guides-and-tutorials/connecting-a-smart-contract-with-a-ui-and-reading-from-the-blockchain">Part 3</a>, we started weaving in the UI and learned how to read from the blockchain. In <a href="https://www.trycrypto.com/guides-and-tutorials/part-4-add-voting-functionality">Part 4</a>, we added voting functionality for both the candidates and learned how to write to the blockchain.</p><p>This part is going to be the final part of this series. Until now, we were simply logging the results on the developer console. In this blog, we will learn how to display the voting results on the UI.</p><p>We will display the results in the form of a table which will look something like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/662/1*6O3Wk8iBQvjWK3DvTKu_cw.png" /></figure><h4>We will achieve this in three simple steps:</h4><ol><li>Create a hidden `&lt;action-button&gt;` that will be fired each time a user votes.</li><li>Create a placeholder table to display the results similar to the above drawn table.</li><li>Modify the `showResults()` function to display the table on the UI.</li></ol><h3>Let’s get started!</h3><h3><strong>Step 1: Create a hidden `&lt;action-button&gt;`</strong></h3><p>This `&lt;action-button&gt;` will be `hidden` so that the user (voter) can’t see the current results of the vote before actually casting their vote.</p><p>Create this `&lt;action-button&gt;` in `dapp-page.js` within `render()` function. This button will be wrapped within a `div` with a unique ID. This `div` should also be `hidden`.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/eb42cf8e0951d40567e687e7ed46338e/href">https://medium.com/media/eb42cf8e0951d40567e687e7ed46338e/href</a></iframe><p>In the above code snippet, you can see that the `hidden` property of the `&lt;action-button&gt;` is set to `true`. This `&lt;action-button&gt;` also has a unique ID `get-candidates`. We set ID to `get-candidates` because this `&lt;action-button&gt;` is essentially fetching all data relevant to the candidates. The most important property of this `&lt;action-button&gt;` is the `.click` property. When this hidden`&lt;action-button&gt;` is clicked, `getCandidates()` method is called. We will take care of clicking this button by manipulating the DOM. This button will be clicked and `getCandidates()` method will be fired as soon as the user (voter) castes their vote.</p><p>Let’s create the `getCandidates()` method within `dapp-page.js`. This function should be near other custom made functions like `showResults()`.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/4bdbd23e63a7203d488364231fc11c95/href">https://medium.com/media/4bdbd23e63a7203d488364231fc11c95/href</a></iframe><p>The function `getCandidates()` fetches data from the blockchain by invoking the smart contract. The received result is then presented in the form of the table with a unique ID `candidate-lookup`. This table will be created in Step 2.</p><h3><strong>Step 2: Create a placeholder table</strong></h3><p>We need to create a placeholder table so that we can populate it dynamically. You can style it in anyway you like. We will use <a href="https://tailwindcss.com/">Tailwind CSS</a>.</p><p>We will add this placeholder table within the `div` we created in Step 1 with ID `tally`.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/9148c91c4d82f9b9b4128440d2be0d9b/href">https://medium.com/media/9148c91c4d82f9b9b4128440d2be0d9b/href</a></iframe><p>Now, we are all set to display the results. The data to be populated is ready to be loaded, and the placeholder is ready to be filled. All we need to do is display the `div` with ID `tally`. We need to take care that the `hidden` `&lt;action-button&gt;` is clicked before the `div` is loaded.</p><h3><strong>Step 3: Modify the `showResults()` function</strong></h3><p>Until now we were just logging the result in the developer console. Now, let’s manipulate the DOM and display the result in the form of a table.</p><p>In the `showResults()` function in `dapp-page.js`, make the following changes:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/d97ca7af6c130ac6b254944a60e8e0ef/href">https://medium.com/media/d97ca7af6c130ac6b254944a60e8e0ef/href</a></iframe><p>We are accessing the DOM by capturing the element by ID `(elid)`. First, we are clicking on the `hidden` `&lt;action-button&gt;` to fire the `getCandidates()` function and then we are removing the `hidden` class from `div` with ID `tally` to make it visible in the DOM.</p><h4>And this was all!</h4><p>Your dapp should now successfully display the current vote tally.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*i-eljAsNX0096Yz4" /></figure><p>This was the final feature we wanted to add to this voting dapp.</p><h4>If you have been following this series and made it till here, congratulations! 🎉</h4><p>We hope you learned how to make an end-to-end full-stack voting dapp on the Ethereum blockchain. We will be coming up with more series with interesting use cases to build on the blockchain.</p><h4>Stay tuned.</h4><h4>Build with DappStarter.</h4><blockquote><a href="https://coincodecap.com/?utm_source=coinmonks">Get Best Software Deals Directly In Your Inbox</a></blockquote><figure><a href="https://coincodecap.com/?utm_source=coinmonks"><img alt="" src="https://cdn-images-1.medium.com/max/584/0*OJ-qb5G6i863msBB.png" /></a></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6026c4b497cd" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coinmonks/how-to-display-voting-results-from-blockchain-on-ui-6026c4b497cd">How To Display Voting Results from Blockchain On UI</a> was originally published in <a href="https://medium.com/coinmonks">Coinmonks</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Add voting functionality]]></title>
            <link>https://medium.com/coinmonks/add-voting-functionality-fcead1e1e56?source=rss-44716129d0a2------2</link>
            <guid isPermaLink="false">https://medium.com/p/fcead1e1e56</guid>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[bitcoin]]></category>
            <category><![CDATA[blockchain]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[ethereum]]></category>
            <dc:creator><![CDATA[Niharika Singh]]></dc:creator>
            <pubDate>Wed, 01 Jul 2020 14:50:25 GMT</pubDate>
            <atom:updated>2020-08-17T12:46:32.188Z</atom:updated>
            <content:encoded><![CDATA[<h3>How to Implement Voting Functionality: From Backend to UI</h3><h4><em>This article is a part of a series called Corporate Governance on Blockchain.</em></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*AnUUgZ0ZJvwiqxFwHY6dHA.png" /></figure><p><a href="https://www.trycrypto.com/blog/how-blockchain-could-change-corporate-governance-for-the-better">Part 1</a> of the series outlines the potential applications of blockchain in corporate governance and walks through how to set up your project to follow this series.</p><p><a href="https://www.trycrypto.com/blog/part-2-voting-smart-contract">Part 2</a> outlines the entire business logic of the shareholder voting smart contract and includes best practices for smart contract development.</p><p>In <a href="https://www.trycrypto.com/guides-and-tutorials/connecting-a-smart-contract-with-a-ui-and-reading-from-the-blockchain">Part 3</a>, we started weaving in the UI and learned how to read from the blockchain.</p><p>In this part, we will add voting functionality for both the candidates and learn how to write to the blockchain.</p><p>By the end of Part 3, our dapp was looking like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/880/0*ZKyMmtQVCQmBXVh3.png" /></figure><p>In this part, we will follow 3 steps to facilitate voting in our dapp.</p><ol><li>Create a voting function in our library, dapp-lib.js. This function will be responsible for writing the votes to the blockchain. (Note: writing to the blockchain is analogous to calling a HTTP POST method and is not free.)</li><li>Add an action button for both the candidates and wire the buttons with the voting function we wrote in step #1 in dapp-lib.js.</li><li>Finally, let’s verify if our voting logic is working correctly. We will call the getCandidates() function again. The voteCount for both the candidates should now be different.</li></ol><h3>Step 1: Create a voting function in our library, dapp-lib.js</h3><p>DappStarter has already generated dapp-lib.js for this purpose. You can find it with this path:</p><pre>packages<br>  - dapplib<br>    - src<br>      - lib<br>        -&gt; dapp-lib.js</pre><p>As a good practice, I would suggest you write this function near the getCandidates() function to make it easier to track which functions you’ve added to the dapp-lib.js file.</p><p>The format of this function will remain similar for all functions that intend to write to the blockchain.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/003b6f08309a26626eecb6160b09709b/href">https://medium.com/media/003b6f08309a26626eecb6160b09709b/href</a></iframe><p>This function will take data as an input parameter. This input object will be received from &lt;action-button&gt; which we will create in the next step in dapp-page.js. Within this data object, there will be a property called candidateId which will also be received from &lt;action-button&gt;.</p><p>Under the hood, dapp-page.js communicates with blockchain.js internally to write to the blockchain. So from dapp-page.js, all we have to do is call the Blockchain.post() method.</p><p>Our work in dapp-lib.js is now done. Let’s move onto dapp-page.js to add action buttons to the UI.</p><h3>Step 2: Add an action button and wire them to the voting logic</h3><p>&lt;action-button&gt; is a custom element that provides an interface to communicate with dapp-lib.js to access functions of our smart contract.</p><p>An &lt;action-button&gt; needs the following tags:</p><ul><li><strong>Source</strong>: This should point to the source div from where data is to be extracted</li><li><strong>Action</strong>: This is the name of the function as we wrote in dapp-lib.js</li><li><strong>Method</strong>: GET/POST</li><li><strong>Fields</strong>: Properties under the data object that will be an input to function in dapp-lib.js</li><li><strong>Text</strong>: This is the text on the button visible to the user</li><li><strong>Class</strong>: CSS class of the button</li><li><strong>.Click</strong>: Function to call when this button is clicked.</li></ul><p>First, let’s add an action button for our first candidate, Miss Kitty. Navigate to render() function in dapp-page.js.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7eb31e1bcab3c9566b7158283511277e/href">https://medium.com/media/7eb31e1bcab3c9566b7158283511277e/href</a></iframe><p>In the above code snippet, we created a hidden &lt;input&gt; with pre-populated value of 0 because candidateId for Miss Kitty is 0. The data-field is set to candidateId because &lt;action-button&gt; will get its data from candidateId. Note that this is wrapped in a div named kitty-form.</p><p>Let’s create the showResults() function. This function will be called whenever &lt;action-button&gt; is clicked. We will create this function in the beginning of dapp-page.js, near constructor(args).</p><p>The name of this function will be showResults(). We will call getCandidates() function in dapp-lib.js and display the results. We will modify this function in later parts when we will present the result in the UI.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/f7ba7c4fc2a0b96f21ecd988d7320ce8/href">https://medium.com/media/f7ba7c4fc2a0b96f21ecd988d7320ce8/href</a></iframe><p>Similarly, we will write an &lt;action-button&gt; for Mr Doggo. Note that value of data-field is 1, and the name of the source div is doggo-form.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/4d1cb06931248fbb72577c69df29d6c9/href">https://medium.com/media/4d1cb06931248fbb72577c69df29d6c9/href</a></iframe><p>After successfully making these changes, your dapp should look like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/880/0*4VRPsRYMgzZKJ5D3.png" /></figure><h3>Step 3: Verify that our voting logic is working correctly</h3><p>We are almost done. Now we just have to verify that it’s working properly.</p><p>To check if everything is working as expected, click on the buttons in the UI. You can click on them multiple times. ;)</p><p>In the developer’s console, you should see something like this. We see a clean table instead of a nested JSON because we did not do console.log() but instead, console.table().</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/880/0*ExmW_X6BR4v6TR06.png" /></figure><p>The terminal should also reflect the transaction occurring on the blockchain. You will be able to see the transaction id, gas usage, block number, and block time. It should look like this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/880/0*Q3xCCm9Ms_iAP-37.png" /></figure><p>In this article, we’ve learned how to add voting functionality for our candidates. As mentioned in Part 1, instead of voting for candidates, you can also choose to vote on agendas. You can customize your dapp in whichever way you like. We also learned how to write to the blockchain. We learned how to work with &lt;action-button&gt;. These custom elements are one of the key magic features of DappStarter.</p><p>We are very close to finishing this dapp. In the next article, we will see how we can display results directly in the UI to make it easy for users to see the current tally for each candidate.</p><blockquote><a href="https://coincodecap.com/?utm_source=coinmonks">Get Best Software Deals Directly In Your Inbox</a></blockquote><figure><a href="https://coincodecap.com/?utm_source=coinmonks"><img alt="" src="https://cdn-images-1.medium.com/max/584/0*OJ-qb5G6i863msBB.png" /></a></figure><h4>Start building with <a href="https://dappstarter.trycrypto.com/">DappStarter</a>.</h4><h4>Stay tuned.</h4><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fcead1e1e56" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coinmonks/add-voting-functionality-fcead1e1e56">Add voting functionality</a> was originally published in <a href="https://medium.com/coinmonks">Coinmonks</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Part 3: How can we connect our smart contract to a UI]]></title>
            <link>https://medium.com/trycrypto/part-3-how-can-we-connect-our-smart-contract-to-a-ui-ee7c95ac6d98?source=rss-44716129d0a2------2</link>
            <guid isPermaLink="false">https://medium.com/p/ee7c95ac6d98</guid>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[blockchain]]></category>
            <category><![CDATA[ethereum]]></category>
            <category><![CDATA[bitcoin]]></category>
            <dc:creator><![CDATA[Niharika Singh]]></dc:creator>
            <pubDate>Tue, 23 Jun 2020 19:22:16 GMT</pubDate>
            <atom:updated>2020-06-24T19:13:26.623Z</atom:updated>
            <content:encoded><![CDATA[<h3>Connect a Smart Contract to a UI</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*2n9JyDEqSyTAbBYEcdBtNA.png" /></figure><p><em>This article is a part of a series called </em><strong><em>Corporate Governance on Blockchain</em></strong><em>.</em></p><p>Read <a href="https://medium.com/@Niharika3297/how-blockchain-could-change-corporate-governance-for-the-better-fb2353ff5b6a">this</a> to learn how blockchain could change corporate governance for the better. Here, you will also find how to set up your project to follow this article series.</p><p>In <a href="https://www.trycrypto.com/blog/how-blockchain-could-change-corporate-governance-for-the-better">Part 1</a> of the series outlines the potential applications of blockchain in corporate governance and walks through how to set up your project to follow this series. <a href="https://www.trycrypto.com/blog/part-2-voting-smart-contract">Part 2</a> outlines the entire business logic of the shareholder voting smart contract and includes best practices for smart contract development.</p><p>In this article, we will learn how to wire up a UI to the smart contract created in <a href="https://www.trycrypto.com/blog/part-2-voting-smart-contract">part 2</a> of this series.</p><h3>Step 1: Expose all smart contract functions as a library</h3><p>On exposing smart contract functions as a library, it becomes very easy to manage the arguments (parameters) and results. This is one of the key steps in connecting the blockchain with our UI.</p><p>DappStarter has already generated dapp-lib.js for this purpose. You can find it using:</p><pre>packages<br>  - dapplib<br>    - src<br>      - lib<br>        -&gt; dapp-lib.js</pre><p>In this file, you can see that all functions that are available in the contracts.</p><p>Let’s create our very own function within dapp-lib.js. You can write them anywhere in the file. I will write them under Examples section.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/ef774c35d39abf3a55ef617f8a194dae/href">https://medium.com/media/ef774c35d39abf3a55ef617f8a194dae/href</a></iframe><p>Dapp-lib.js abstracts all the complex communication with the blockchain. So you, as a developer, don’t need to set up Web3 library for your project from scratch. All the code responsible for managing blockchain (inputs and outputs) can be found in blockchain.js. DappStarter is designed in a way that you wouldn’t really need to tweak blockchain.js. Dapp-Lib.js does that for you.</p><p>It’s as simple as that.</p><p>Let’s test out the getCandidates() function we just created in Dapp-lib.js. To do so, let’s call getCandidates() function from constructor() function in dapp-page.js and print the result.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7c049ec2534e340817444d0ded336a71/href">https://medium.com/media/7c049ec2534e340817444d0ded336a71/href</a></iframe><p>This returns a resolved promise. This promise contains all the required data — name and voteCount.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/880/0*Hh2pspZGCmfiYxQc.png" /></figure><p>This verifies that our function getCandidates is working properly.</p><h3>Step 2: Get icons for candidates</h3><p>Thanks to <a href="https://dribbble.com/vaneltia">Alfrey Davilla</a> for creating such cute icons. :)</p><p>Our two candidates are <em>Ms. Kitty</em> and <em>Mr. Doggo</em> :</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/880/0*rZI-LgB2ipnIypcf.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/0*crmHIPUUN277_fbX.jpg" /></figure><ul><li>You can download the picture of the cat from <a href="https://dribbble.com/shots/10836458-Cat-Playing-Slime">here</a>.</li><li>You can download the picture of the dog from <a href="https://medium.com/@grifer163/alfrey-davilla-vaneltia-54eaf3ba6162">here</a>.</li></ul><p>As a good practice you should save static assets in:</p><pre>packages<br>  - client<br>    - src<br>      - dapp<br>        - assets<br>          - img<br>            -&gt; kitty.png<br>            -&gt; doggo.png</pre><h3>Step 3: Import icons</h3><p>Now let’s import these images in dapp-page.js. You can find dapp-page.js in:</p><pre>packages<br>  - client<br>    - src<br>      - dapp<br>        - pages<br>          -&gt; dapp-page.js</pre><p>In the beginning of the file, you can add the code:</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/333c48822538a64fb9944d32cdef19dd/href">https://medium.com/media/333c48822538a64fb9944d32cdef19dd/href</a></iframe><h3>Step 4: Set up CSS structure to make a placeholder for candidates</h3><p>DappStarter uses <a href="https://tailwindcss.com/">Tailwind CSS</a>. You can even add your own components in dapp-page.js under render() function.</p><p><a href="https://gist.github.com/niharrs/11214ec335a500830361d1150d490979#file-dapp-page-js">https://gist.github.com/niharrs/11214ec335a500830361d1150d490979#file-dapp-page-js</a></p><p>Your dapp should look like this now-</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/880/0*hFU_oV8nyTuzKREu.png" /></figure><p>In this article, we’ve learned how to expose our functions as a library in dapp-lib.js to communicate with the blockchain. We also learned how to read data from the blockchain and how the basic UI works in DappStarter.</p><p>Our dapp is coming together well now. In the next article, we will add voting logic so shareholders can cast their vote to be written to the blockchain. We will also explore how DappStarter manages UI in more depth.</p><h3>Start building with DappStarter.</h3><h3>Stay tuned for part 4!</h3><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ee7c95ac6d98" width="1" height="1" alt=""><hr><p><a href="https://medium.com/trycrypto/part-3-how-can-we-connect-our-smart-contract-to-a-ui-ee7c95ac6d98">Part 3: How can we connect our smart contract to a UI</a> was originally published in <a href="https://medium.com/trycrypto">TryCrypto (now Decentology)</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How To Implement A Voting Smart Contract]]></title>
            <link>https://medium.com/trycrypto/how-to-implement-a-voting-smart-contract-de26bc877467?source=rss-44716129d0a2------2</link>
            <guid isPermaLink="false">https://medium.com/p/de26bc877467</guid>
            <category><![CDATA[blockchain]]></category>
            <category><![CDATA[bitcoin]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[ethereum]]></category>
            <category><![CDATA[technology]]></category>
            <dc:creator><![CDATA[Niharika Singh]]></dc:creator>
            <pubDate>Tue, 16 Jun 2020 17:13:19 GMT</pubDate>
            <atom:updated>2020-06-16T17:17:01.292Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*wWZfWRIjUJIZJQYfxGtVkg.png" /></figure><p><a href="https://www.trycrypto.com/blog/how-blockchain-could-change-corporate-governance-for-the-better">Part 1</a> of the series outlines the potential applications of blockchain in corporate governance. It also provides an overview of the technical architecture of the shareholder voting solution to be implemented in this series and walks through how to set up your project to follow this series. Read part 1 <a href="https://www.trycrypto.com/blog/how-blockchain-could-change-corporate-governance-for-the-better">here</a>.</p><p>In this article, we will write a shareholder voting smart contract using Solidity.</p><p>Here is the overview of the idea we want to capture in the smart contract. We will write a function to:</p><ul><li>Add candidates</li><li>Get candidates</li><li>Cast a vote</li></ul><p>We will assume that each ‘Annual General Meeting (AGM)’, the annual meeting where shareholders vote on agendas to make key decisions for the company, will be different, so a different smart contract would be developed for each one.</p><p>Assuming that you’ve set up your project. You can find Dapp.sol</p><pre>packages<br>  - dapplib<br>    - contracts<br>      -&gt; Dapp.sol</pre><p>Let’s start by defining what our candidate will look like. For sake of simplicity, let’s assume it will have an id, name and, voteCount.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/178ab497d530b067289e6567b4251aa8/href">https://medium.com/media/178ab497d530b067289e6567b4251aa8/href</a></iframe><p>Now, let’s define the addCandidate function. This function&#39;s job is to create a candidate listing on the blockchain. Instead of a candidate, you can also vote on agendas. The choice is yours.</p><p>The initial voteCount for each candidate will be zero.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/857b019d41741a19ed8d76fa3bc0e016/href">https://medium.com/media/857b019d41741a19ed8d76fa3bc0e016/href</a></iframe><p>We want to invoke the addCandidate function as soon as the smart contract is deployed, so we will call it from the Constructor() function.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/3b2d51084936a65bd6f727b50d5aa9dd/href">https://medium.com/media/3b2d51084936a65bd6f727b50d5aa9dd/href</a></iframe><p>The next step would be to fetch all candidates. There are two approaches you could choose from:</p><ol><li><strong>Fetch candidates by ID:</strong> This means that if there are 50 candidates, each user will have to query the smart contracts 50 times. Let’s say there are 20,000 voters, this means that your smart contract will be invoked 20,000 * 50 times (1,000,000 times). I don’t think this is wise, you’d end up wasting a lot of bandwidth. Nonetheless, I’ll still show you what this code might look like.</li></ol><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/9338e3f765f1254da99260194519549c/href">https://medium.com/media/9338e3f765f1254da99260194519549c/href</a></iframe><p><strong>2. Fetch all candidates at once.</strong> You will return ALL candidates at once. This means your smart contract will be invoked 20,000 times (# of users) instead of a million times. This is the approach we will go with.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/ec722b5b6a1c06337b62de201c548cb4/href">https://medium.com/media/ec722b5b6a1c06337b62de201c548cb4/href</a></iframe><p>Here we are returning an array of names and an array of voteCounts. We can manipulate these arrays later using JavaScript to fit our needs.</p><p><strong>Note 1:</strong> Since getCandidates() is NOT called from within the smart contract but will be called from the outside, we will use external keyword here.</p><p><strong>Note 2:</strong> getCandidates() is a read only function. Reading from the blockchain is free. So we use the keyword view here.</p><p>Finally we need to add voting logic in our smart contract. Let’s call this function vote. Since this function will be called from outside of the smart contract, we will use external keyword here. We will NOT use view keyword because this function writes your vote to the blockchain and writing to the blockchain is not free.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/98d02a49c57bad930242031d04658f40/href">https://medium.com/media/98d02a49c57bad930242031d04658f40/href</a></iframe><p>At the end, your smart contract should look like this-</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/241e17575fa05d50434eb2c3209b381a/href">https://medium.com/media/241e17575fa05d50434eb2c3209b381a/href</a></iframe><p>In this article, we explored the various approaches to writing a resource-efficient smart contract. We also covered the important keywords (external, view) to understand and use properly when developing a smart contract. In part 3, we’ll outline how to connect your smart contract to a UI to make it simple for shareholders to interact with the smart contract functions we’ve written here.</p><p>Start building with <a href="https://dappstarter.trycrypto.com/">DappStarter</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=de26bc877467" width="1" height="1" alt=""><hr><p><a href="https://medium.com/trycrypto/how-to-implement-a-voting-smart-contract-de26bc877467">How To Implement A Voting Smart Contract</a> was originally published in <a href="https://medium.com/trycrypto">TryCrypto (now Decentology)</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Learn How to Create a Passion Economy Platform on Blockchain]]></title>
            <link>https://medium.com/coinmonks/learn-how-to-create-a-passion-economy-platform-on-blockchain-25ea896ae4da?source=rss-44716129d0a2------2</link>
            <guid isPermaLink="false">https://medium.com/p/25ea896ae4da</guid>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[bitcoin]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[blockchain]]></category>
            <category><![CDATA[web-development]]></category>
            <dc:creator><![CDATA[Niharika Singh]]></dc:creator>
            <pubDate>Fri, 08 May 2020 16:42:25 GMT</pubDate>
            <atom:updated>2020-08-21T16:48:55.503Z</atom:updated>
            <content:encoded><![CDATA[<h4>“The line between hobbies, careers and personal brands is blurring.” — Adam Davidson, author of “The Passion Economy: The New Rules for Thriving in the 21st century”</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PNKY8X501Au0bdO3qz_e3A.png" /></figure><p>The passion economy is all about monetizing individuality. Successful people usually have a unique skill set that is uncommon and hard to find elsewhere. When you combine your passion with skills, you can carve out a perfect niche in the economy.</p><p>The nature of work as we see it today is changing rapidly. Post COVID-19 crisis, we don’t know if we can go back to the way we were. Who thought they would be writing their end semester exams from their dorm!? Do we really need brick and mortar to run an office? COVID-19 is making us challenge the status quo.</p><p>The beginning of the journey into the passion economy starts with you. (This is usually the hardest step.) The passion economy is all about monetizing your individuality, so step #1 is reflecting within to find what you’re truly passionate about. This idea resonates with many religions where the focus is on finding a greater purpose in life and to work towards it with raw passion.</p><p>And passion pays off. According to <a href="https://a16z.com/2019/10/08/passion-economy/">a16z</a>, the top-earning writer on the paid newsletter platform Substack earns more than $500,000 a year from reader subscriptions. The top content creator on Podia, a platform for video courses and digital memberships, makes more than $100,000 a month. And teachers across the US are bringing in thousands of dollars a month teaching live, virtual classes on Outschool and Juni Learning.</p><p>Yet, so many platforms lack transparency for content creators. In this blog post, we will focus on leveraging blockchain to create a passion economy platform for writers.</p><h3>Here’s a step-by-step guide on how to develop a journal entry prototype on the Ethereum blockchain using Sia as a decentralized storage platform.</h3><p>We will build a platform where a user can make a journal entry and push it to a decentralized storage platform. The unique hash of the journal entry will be stored on the blockchain. We will also fetch previous journal entries.</p><p>Sia is an open source decentralized storage platform that leverages blockchain technology to create a data storage marketplace. It is more robust and affordable when compared to traditional cloud storage providers. You don’t require any signups, servers, or need to trust third parties. Sia keeps your data private. You control your private encryption keys and you own your data. No third party has access to your files, unlike traditional cloud storage providers. Learn more about Sia <a href="https://sia.tech/">here</a>.</p><p>DappStarter is a full-stack blockchain app generator. We’ll be using DappStarter to spin up a minimalistic blockchain dapp within 5 minutes. DappStarter makes development faster and more efficient so developers can focus on the smart contract’s business logic, saving weeks of learning and development time. Learn more about DappStarter <a href="http://trycrypto.com/">here</a>.</p><h3>Checklist before starting:</h3><ul><li><a href="https://code.visualstudio.com/download">Visual Studio Code</a> (or any IDE for editing JavaScript)</li><li><a href="https://nodejs.org/en/download/">NodeJS v10.x</a></li><li><a href="https://www.npmjs.com/package/solc">Solidity v0.5.11</a></li><li><a href="https://truffleframework.com/truffle">Truffle v5.0.7</a></li><li><a href="https://truffleframework.com/ganache">Ganache v2.0.0</a> — Blockchain simulator for Ethereum</li></ul><h3>Step 1: Go to <a href="https://dappstarter.trycrypto.com/">dappstarter.trycrypto.com</a> to generate your blockchain dapp</h3><p>DappStarter supports your choice of blockchain and blockchain language as well as an integrated front end user experience in your choice of client side framework.</p><h4>Step 1.1: Select your choice of blockchain. For this tutorial, we will use Ethereum.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*VDUzp4cGxUE8bZRy" /></figure><h4>Step 1.2: Select Solidity as smart contract language</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*BFMmiUcpkCQbFyFI" /></figure><h4>Step 1.3: For now we will work with vanilla JS</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*WZYNAvoWLLBwtIVO" /></figure><h4>Step 1.4: Select a name for your dapp and click on the ‘CREATE DAPP’ button! 🎉</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/480/0*XtmY1UFSb9O8_OFO" /></figure><p>If you have followed all these steps successfully, you should have a unique github repository link where you can find your dapp!</p><h3>Step 2: Go to the GitHub repository and start your dapp using README</h3><p>Once you have successfully started your dapp, you should see something like this-</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*0zIsE_He0WaXOlMv" /></figure><p>To get an overview of DappStarter, go to <a href="https://www.trycrypto.com/blockchain-bootcamp-get-your-dapp-running-in-1-hour">trycrypto.com/</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*nhhA8Aw_3eMkfelB" /></figure><h3>Step 3: Customize your dapp</h3><p>Let’s see how we can modify the navigation pane. Go to src/dapp/pages/components/page-navigation.js</p><p>You can find all the code related to dapp navigation here.</p><pre>…</pre><pre>getPages() {</pre><pre>let staticPages = [{</pre><pre>name: ‘dapp’,</pre><pre><strong>title: ‘Start Writing!’,</strong></pre><pre>route: ‘/’</pre><pre>}, {</pre><pre>name: ‘admin’,</pre><pre>title: ‘Dapp Admin’,</pre><pre>route: ‘/admin’,</pre><pre>hidden: true</pre><pre>}]</pre><pre>return staticPages.concat([{“name”:”administrator_role”,”title”:”Administrator Role”,”description”:”Define accounts that can perform certain admin functions.”,”category”:”Access Control”,”route”:”/administrator_role”},{“name”:”contract_access”,”title”:”Contract Access”,”description”:”Control which external contracts can interact with your contract.”,”category”:”Access Control”,”route”:”/contract_access”},{“name”:”contract_runstate”,”title”:”Contract Run State”,”description”:”Ability to pause operation of your smart contract.”,”category”:”Access Control”,”route”:”/contract_runstate”}]);</pre><pre>…</pre><p>On saving the file, the dapp will be reloaded automatically because DappStarter uses webpack. Now, you should see a navigation panel and Start Writing page like this-</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*rbZdGJn_bIu3tX_j" /></figure><h3>Step 4: Create a new widget to make our dapp modular</h3><p>It’s good practice to create widgets for different functionalities. Create a file named html-widget.js in src/lib/components/widgets.</p><p>Insert the following code in this file</p><pre>import CustomElement from ‘../shared/custom-element’;</pre><pre>export default class HtmlWidget extends CustomElement {</pre><pre>static get ATTRIBUTE_FIELD() {</pre><pre>return ‘field’</pre><pre>}</pre><pre>static get ATTRIBUTE_LABEL() {</pre><pre>return ‘label’</pre><pre>}</pre><pre>static get ATTRIBUTE_PLACEHOLDER() {</pre><pre>return ‘placeholder’</pre><pre>}</pre><pre>static get observedAttributes() {</pre><pre>return HtmlWidget.attributes;</pre><pre>}</pre><pre>static get attributes() {</pre><pre>return [</pre><pre>HtmlWidget.ATTRIBUTE_FIELD,</pre><pre>HtmlWidget.ATTRIBUTE_LABEL,</pre><pre>HtmlWidget.ATTRIBUTE_PLACEHOLDER</pre><pre>];</pre><pre>}</pre><pre>constructor(…args) {</pre><pre>super(HtmlWidget.attributes, …args);</pre><pre>this.quill = null;</pre><pre>}</pre><pre><strong>get value() {</strong></pre><pre><strong>let markup = this.quill.container.querySelector(‘.ql-editor’).innerHTML;</strong></pre><pre><strong>return `&lt;html&gt;</strong></pre><pre><strong>&lt;head&gt; &lt;/head&gt;</strong></pre><pre><strong>&lt;body&gt;</strong></pre><pre><strong>&lt;div style=”font-family:lato;”&gt;</strong></pre><pre><strong>${markup}</strong></pre><pre><strong>&lt;/div&gt;</strong></pre><pre><strong>&lt;/body&gt;</strong></pre><pre><strong>&lt;/html&gt;`</strong></pre><pre><strong>}</strong></pre><pre>render() {</pre><pre>let self = this;</pre><pre>let content = `</pre><pre>&lt;div class=”input-group”&gt;</pre><pre>&lt;div id = “editor” class = “form-control”&gt; &lt;/div&gt;</pre><pre>&lt;/div&gt;</pre><pre>`</pre><pre>self.style.display = ‘block’;</pre><pre>if (self.nextSibling) {</pre><pre>self.classList.add(‘mb-3’)</pre><pre>}</pre><pre>self.innerHTML = content;</pre><pre><strong>var toolbarOptions = [</strong></pre><pre><strong>[‘bold’, ‘italic’, ‘underline’, ‘strike’], // toggled buttons</strong></pre><pre><strong>[‘blockquote’, ‘code-block’],</strong></pre><pre><strong>[{ ‘header’: 1 }, { ‘header’: 2 }], // custom button values</strong></pre><pre><strong>[{ ‘list’: ‘ordered’}, { ‘list’: ‘bullet’ }],</strong></pre><pre><strong>[{ ‘script’: ‘sub’}, { ‘script’: ‘super’ }], // superscript/subscript</strong></pre><pre><strong>// [{ ‘indent’: ‘-1’}, { ‘indent’: ‘+1’ }], // outdent/indent</strong></pre><pre><strong>// [{ ‘direction’: ‘rtl’ }], // text direction</strong></pre><pre><strong>// [{ ‘size’: [‘small’, false, ‘large’, ‘huge’] }], // custom dropdown</strong></pre><pre><strong>[{ ‘header’: [1, 2, 3, 4, 5, 6, false] }],</strong></pre><pre><strong>[{ ‘color’: [] }, { ‘background’: [] }], // dropdown with defaults from theme</strong></pre><pre><strong>// [{ ‘font’: [] }],</strong></pre><pre><strong>// [{ ‘align’: [] }],</strong></pre><pre><strong>[‘clean’] // remove formatting button</strong></pre><pre><strong>];</strong></pre><pre><strong>self.quill = new Quill(‘#editor’, {</strong></pre><pre><strong>modules: {</strong></pre><pre><strong>toolbar: toolbarOptions</strong></pre><pre><strong>},</strong></pre><pre><strong>theme: ‘snow’</strong></pre><pre><strong>});</strong></pre><pre>}</pre><pre>}</pre><pre>customElements.define(‘html-widget’, HtmlWidget);</pre><p>In this file, we have integrated <a href="https://quilljs.com/">Quill to</a> make rich text journal entries. Quill is a free,<a href="https://github.com/quilljs/quill/"> open source</a> WYSIWYG editor built for the modern web.</p><p>To use Quill’s functionalities, make sure you add Quill CDNs in dapp/index.html. In the head, add &lt;link href=”<a href="https://cdn.quilljs.com/1.3.6/quill.snow.css">https://cdn.quilljs.com/1.3.6/quill.snow.css</a>&quot; rel=”stylesheet”&gt; and just before closing body, add &lt;script src=”<a href="https://cdn.quilljs.com/1.3.6/quill.js">https://cdn.quilljs.com/1.3.6/quill.js</a>&quot;&gt;&lt;/script&gt;</p><p>To increase length of the text editor, make the following changes to src/dapp/index.css-</p><pre>…</pre><pre>#editor {</pre><pre>height: 375px;</pre><pre>}</pre><pre>strong { font-weight: bold !important; }</pre><pre>…</pre><h3>Step 5: Make use of html-widget in our dapp</h3><p>Go to src/dapp/pages/dapp-page.js (this is where all our dapp front-end logic will reside) and make the following changes. Import the created html-widget there. We will be able to use this widget like a regular html tag to use Quill editor anywhere in our dapp.</p><pre>import DappLib from ‘../../lib/dapp-lib’;</pre><pre>import CustomElement from ‘../../lib/components/shared/custom-element’;</pre><pre>import DOM from ‘../../lib/components/shared/dom’;</pre><pre>import ‘../../lib/components/shared/action-card.js’;</pre><pre>import ‘../../lib/components/widgets/number-widget.js’;</pre><pre><strong>import ‘../../lib/components/widgets/html-widget.js’;</strong></pre><pre>import ActionButton from ‘../../lib/components/shared/action-button’;</pre><pre>import canvas from ‘../assets/img/canvas.jpg’;</pre><pre>export default class SiaPage extends CustomElement {</pre><pre>constructor(…args) {</pre><pre>super([], …args);</pre><pre>this.mode = ‘multiple’;</pre><pre>this.files = [];</pre><pre>this.eventHandlerRegistered = false;</pre><pre>}</pre><pre>render() {</pre><pre>let self = this;</pre><pre><strong>self.category = “Maintain your journal on decentralized web”;</strong></pre><pre><strong>self.description = “Store your journal on decentralized file storage”;</strong></pre><pre>let uiHtml = {</pre><pre>[CustomElement.UI_READ]: ‘’,</pre><pre>[CustomElement.UI_WRITE]: ‘’,</pre><pre>[CustomElement.UI_ADMIN]: ‘’</pre><pre>}</pre><pre>uiHtml[CustomElement.UI_READ] =</pre><pre>`</pre><pre>&lt;action-card</pre><pre>title=”Get Document” description=”Get Sia document using its ID”</pre><pre>action=”getSiaDocument” method=”${CustomElement.METHOD_GET}” fields=”id”&gt;</pre><pre>&lt;number-widget</pre><pre>field=”id” label=”Doc ID” placeholder=”Document ID”&gt;</pre><pre>&lt;/number-widget&gt;</pre><pre>&lt;/action-card&gt;</pre><pre>&lt;action-card</pre><pre>title=”Get Documents by Owner” description=”Get all Sia documents for any account”</pre><pre>action=”getSiaDocumentsByOwner” method=”${CustomElement.METHOD_GET}” fields=”account”&gt;</pre><pre>&lt;account-widget</pre><pre>field=”account” label=”Account” placeholder=”Account address”&gt;</pre><pre>&lt;/account-widget&gt;</pre><pre>&lt;/action-card&gt;</pre><pre>`</pre><pre>uiHtml[CustomElement.UI_WRITE] =</pre><pre>`</pre><pre>&lt;action-card</pre><pre>title=”Make a journal entry” description=”Upload entry to Sia and add hash to contract”</pre><pre>action=”addSiaDocument” method=”${CustomElement.METHOD_POST}” fields=”myText”</pre><pre>target=”card-body-addSiaDocument”</pre><pre>message=”Waiting for Sia upload and smart contract transaction”&gt;</pre><pre><strong>&lt;h2&gt; Start Writing! &lt;/h2&gt;</strong></pre><pre><strong>&lt;html-widget</strong></pre><pre><strong>data-field= “myText” field=”label” label=”Label”</strong></pre><pre><strong>placeholder=”Description”&gt;</strong></pre><pre><strong>&lt;/html-widget&gt;</strong></pre><pre><strong>&lt;input type=”hidden” data-field=”mode” value=”${self.mode}” style=”display:none;”&gt;&lt;/input&gt;</strong></pre><pre><strong>&lt;/action-card&gt;</strong></pre><pre>`</pre><pre>let content =</pre><pre>`</pre><pre>&lt;page-body title=”${self.title}” category=”${self.category}” description=”${self.description}”&gt;</pre><pre>${uiHtml[CustomElement.UI_READ]}</pre><pre>${uiHtml[CustomElement.UI_WRITE]}</pre><pre>${uiHtml[CustomElement.UI_ADMIN]}</pre><pre>&lt;/page-body&gt;</pre><pre>&lt;page-panel id=”resultPanel”&gt;&lt;/page-panel&gt;</pre><pre>`</pre><pre>self.innerHTML = content;</pre><pre>// self.querySelector(‘upload-widget’).addEventListener(UploadWidget.EVENT_FILES_CHANGED, (e) =&gt; {</pre><pre>// //Could do something here</pre><pre>// //let files = e.detail.files;</pre><pre>// });</pre><pre>if (!self.eventHandlerRegistered) {</pre><pre>self.eventHandlerRegistered = true;</pre><pre>DappLib.onAddSiaDocument((result) =&gt; {</pre><pre>let resultPanel = self.querySelector(‘#resultPanel’);</pre><pre>resultPanel.append(DappLib.getFormattedResultNode(result));</pre><pre>resultPanel.open();</pre><pre>});</pre><pre>}</pre><pre>}</pre><pre>async fetchAndDisplayCounter() {</pre><pre>let result = await DappLib[‘getStateCounter’].call();</pre><pre>DOM.elid(‘counter’).innerHTML = result.callData;</pre><pre>}</pre><pre>}</pre><pre>customElements.define(‘dapp-page’, DappPage);</pre><p>Your dapp should look like this now-</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*8TfCz40iu9NCDcls" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*UL1kJWpCWh52An9z" /></figure><h3>Step 6: Remove extra blocks and change logo</h3><p>Let’s take the customization of the dapp to the next level. Let’s make it look like this-</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*cbQ0huryMB6dYzPZ" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*438FshaeFl9UjHs9" /></figure><p>Let’s change the logo first. You can use any image. Save it in src/dapp/assets/img. Let’s name it YOUR_FILE_NAME.png. Now go to src/dapp/pages/components/page-navigation.js. You see this line in the code-</p><pre>import logo from “../../../dapp/assets/img/dappstarter.png”;</pre><p>Change it to</p><pre><strong>import logo from “../../../dapp/assets/img/YOUR_FILE_NAME.png”;</strong></pre><p>We also need to make a change to webpack.config.dapp.js (this is in the root of the project)-</p><pre>…</pre><pre>plugins: [</pre><pre>new HtmlWebpackPlugin({</pre><pre>template: path.join(__dirname, ‘src/dapp/index.html’)</pre><pre>}),</pre><pre><strong>new FaviconsWebpackPlugin(‘src/dapp/assets/img/YOUR_FILE_NAME.png’)</strong></pre><pre>],</pre><pre>…</pre><p>This is what your dapp should look like now-</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*V_OOOA2zpf8IFq6t" /></figure><p>Now let’s remove the Feature blocks from the left navigation panel. Go to src/dapp/pages/components/page-navigation.js.</p><pre>…</pre><pre>// Remove the block between //BEGIN //END below to remove feature blocks from navigation</pre><pre>// BEGIN: Feature Blocks</pre><pre>// DOM.h4({</pre><pre>// className: ‘mt-5 mb-2’</pre><pre>// },</pre><pre>// “Feature Blocks”),</pre><pre>// DOM.ul({</pre><pre>// id: self.listId + ‘-blocks’,</pre><pre>// className: ‘list-group list-group-flush’</pre><pre>// },</pre><pre>// listItems.slice(1)</pre><pre>// ),</pre><pre>// END: Feature Blocks</pre><pre>…</pre><p>Your dapp should look like this now-</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*sYpTwpoRPVWmgiEZ" /></figure><p>We are almost there!! Finally, let’s get rid of the top navigation bar. Go to src/dapp/pages/components/top-navigation.js and remove all the html that is being rendered.</p><p>src/dapp/pages/components/top-navigation.js should look like this-</p><pre>import CustomElement from ‘../../../lib/components/shared/custom-element’;</pre><pre>export default class TopNavigation extends CustomElement {</pre><pre>static get ATTRIBUTE_COLLAPSE() {</pre><pre>return ‘collapse’</pre><pre>}</pre><pre>static get observedAttributes() {</pre><pre>return TopNavigation.attributes;</pre><pre>}</pre><pre>static get attributes() {</pre><pre>return [</pre><pre>TopNavigation.ATTRIBUTE_COLLAPSE</pre><pre>];</pre><pre>}</pre><pre>constructor(…args) {</pre><pre>super(TopNavigation.attributes, …args);</pre><pre>}</pre><pre>}</pre><pre>customElements.define(‘top-navigation’, TopNavigation);</pre><p>This is what your dapp should look like now-</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*vSE9etuTXkYwXeG-" /></figure><h3>Step 7: Handle journal entry with Sia</h3><p>All the code related to Sia document upload rests in src/lib/dapp-lib.js. Go to FILE STORAGE: SIA section. The only code block that needs editing here is addSiaDocument().</p><pre>static async addSiaDocument(data) {</pre><pre>let folder = data.mode === ‘folder’;</pre><pre>let config = DappLib.getConfig();</pre><pre><strong>//Name of the journal entry is the date and time when it was written</strong></pre><pre><strong>const timeStamp = new Date().toString();</strong></pre><pre><strong>// Convert data received from html-widget into a file</strong></pre><pre><strong>data.files = [new File([data.myText], `${timeStamp}.html`, {</strong></pre><pre><strong>type: “text/html”,</strong></pre><pre><strong>})];</strong></pre><pre><strong>// Push files to SIA</strong></pre><pre><strong>let siaResult = await DappLib.siaUpload(config, data.files, folder);</strong></pre><pre>let results = [];</pre><pre>for(let f=0; f&lt;siaResult.length; f++) {</pre><pre>let file = siaResult[f];</pre><pre>let result = await Blockchain.post({</pre><pre>config: config,</pre><pre>contract: DappLib.DAPP_STATE_CONTRACT,</pre><pre>params: {</pre><pre>from: null,</pre><pre>gas: 2000000</pre><pre>}</pre><pre>},</pre><pre>‘addSiaDocument’,</pre><pre>file.docId,</pre><pre>DappLib.fromAscii(data.label || ‘’, 32)</pre><pre>);</pre><pre>results.push({</pre><pre>transactionHash: DappLib.getTransactionHash(result.callData),</pre><pre>docId: file.docId</pre><pre>});</pre><pre>}</pre><h3>Step 8: Final touch ups</h3><p>Our dapp is almost ready. We just need to make a few tweeks in src/dapp/index.css. Add the following lines to the file-</p><pre>.markup {</pre><pre>font-family:courier;</pre><pre>}</pre><h3>These were all the changes we had to make! Now let’s see our dapp in action.</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/480/0*sKVJUncgu4PgE2Fq" /></figure><h3>Congratulations, if you made it till here! 🎉</h3><p>You can modify your dapp to develop more sophisticated platforms for writers. What we built was merely an example of one of the many use cases you as a developer could build upon.</p><p>The future of the passion economy is predicated on the concept of transparency and fairness for content creators. Blockchain provides a unique infrastructure that encourages creators to make awesome content by ensuring that they’ll be fairly compensated for their efforts. Building a dapp for the passion economy is about more than just monetizing content — it’s about providing a transparent, open system where creators feel empowered to create and share what makes them unique.</p><h3>Start building your dapp with DappStarter.</h3><blockquote><a href="https://coincodecap.com/?utm_source=coinmonks">Get Best Software Deals Directly In Your Inbox</a></blockquote><figure><a href="https://coincodecap.com/?utm_source=coinmonks"><img alt="" src="https://cdn-images-1.medium.com/max/584/0*OJ-qb5G6i863msBB.png" /></a></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=25ea896ae4da" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coinmonks/learn-how-to-create-a-passion-economy-platform-on-blockchain-25ea896ae4da">Learn How to Create a Passion Economy Platform on Blockchain</a> was originally published in <a href="https://medium.com/coinmonks">Coinmonks</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How Blockchain Could Change Corporate Governance for the Better]]></title>
            <link>https://medium.com/swlh/how-blockchain-could-change-corporate-governance-for-the-better-fb2353ff5b6a?source=rss-44716129d0a2------2</link>
            <guid isPermaLink="false">https://medium.com/p/fb2353ff5b6a</guid>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[ethereum]]></category>
            <category><![CDATA[bitcoin]]></category>
            <category><![CDATA[business]]></category>
            <category><![CDATA[blockchain]]></category>
            <dc:creator><![CDATA[Niharika Singh]]></dc:creator>
            <pubDate>Thu, 30 Apr 2020 11:41:50 GMT</pubDate>
            <atom:updated>2020-04-30T11:41:50.367Z</atom:updated>
            <content:encoded><![CDATA[<h4><strong><em>In </em></strong><a href="https://perma.cc/4B8S-ZRD4"><strong><em>2017</em></strong></a><strong><em>, 437 billion shares were voted across 4000 corporate meetings. Many of the voting results had a victory margin of less than one percent!</em></strong></h4><p><strong>There’s lots of talk in the blockchain space </strong>about how blockchain can be used to facilitate voting in the political sphere, but there is less talk on the very real and very impactful use case of voting in the realm of corporate governance.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vErEPCnKgm5az4_kz_LIug.png" /></figure><p><strong>Shareholder franchise, </strong>the concept that shareholders have a right to participate in corporate decision-making, is at the core of corporate governance. Every year, shareholders are summoned to vote on important corporate agendas like election of new board of directors, modification of bylaws, approval of mergers, etc.</p><h4><strong>Shareholder voting is expensive and error-prone</strong></h4><p>Imagine you are one of the many shareholders of a hypothetical company <em>Crypto Inc. </em>Crypto Inc. has decided to appoint a new member to its board of directors. You have been invited to cast your vote in this regard. Unfortunately, you can’t make it to the shareholder meeting. So you decide to mail them your response.</p><p>It’s highly probable that many other shareholders also would also not be able to attend the shareholder meeting in person. So most likely, even they would send out their vote in the mail or send their delegate to the meeting as a proxy.</p><p>But you wonder: Did Crypto Inc. count your vote? What if they misplaced your mail by mistake or purposefully? If your response was kept confidential or not?</p><p>For Crypto Inc. as well, hosting shareholder meetings is a cumbersome process. They are expensive, slow, and prone to errors.</p><p><strong>Let’s look at real life examples illustrating problems with the current system…</strong></p><p>Many intermediaries get involved as a company tries to put an agenda on vote. For example; brokers, banks, proxy service providers, proxy advisory firms, vote tabulators etc. Any error at any level would get compounded as information travels from one participant to another. At the moment, each participant is seen as a hindrance to efficiency, but the same protocol has to be followed because there is no other option.</p><p>In <a href="https://perma.cc/NZF5-W68H">2017</a>, at Procter &amp; Gamble (P&amp;G), Nelon Peltz wanted to compete for a seat on the company’s board. When the results came out, he lost. P&amp;G claimed victory by 6 million votes out of 2 billion votes. Peltz challenged the outcome, and demanded a recount. A different vote tabulator was appointed and recounting was done. After recounting, <a href="https://www.cnbc.com/2017/12/18/pg-appoints-peltz-to-board-despite-losing-proxy-battle.html">Peltz turned out to be the victo</a>r by a margin of 42,780 votes.</p><p>In February 2008, <a href="https://www.money-zine.com/investing/investing/proxy-contest/">Microsoft made an offer to buy Yahoo! for $31 per share</a>. The board of directors at Yahoo! declined the offer. Soon after, Yahoo! announced that it received approval for a slate of directors from 80% shareholders. This actually never happened. Broadridge, a proxy service firm, misreported 20% of votes because it didn’t include millions of voters in the final tally.</p><p>The current system gives 3rd parties significant power with little transparency, leaving room for serious errors. ENTER blockchain!</p><h4><strong>Voting on blockchain will by design make the environment auditable without requiring 3rd parties.</strong></h4><p>In a blockchain-based corporate governance system:</p><ul><li>All ecosystem participants can audit the votes by querying the blockchain at their convenience.</li><li>Shareholders can safely exercise their right to vote without worrying if their vote is counted or not, or if their response was kept confidential or not.</li><li>Such a voting system has the potential to eliminate the complexity and cost of the legacy proxy voting value chain by eradicating/reducing the role of intermediaries.</li><li>Companies would be able to propose voting agendas more frequently at a lower cost. The outcome of the agenda would be much faster and more accurate.</li></ul><h4>These factors could improve overall confidence in the ecosystem, which can fuel more effective and transparent corporate governance.</h4><h3>A blockchain-enabled shareholder voting system might look something like this in your local development environment.</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*RWh55DkanCKoYNoM" /></figure><p>Specific individuals at Crypto Inc. can create new agenda items. Once the agenda is on the floor, the shareholders can vote from the dapp’s UI. Each vote is committed to the blockchain via a smart contract, so the ecosystem remains transparent and auditable.</p><p>Want to build a dapp like the example above? Starting from scratch is time-consuming and frustrating. Generate a custom dapp with DappStarter, then tailor to fit your needs. DappStarter accelerates blockchain development so that you can focus on your smart contract’s business logic, saving weeks of learning and development time. You can see DappStarter in action <a href="https://www.trycrypto.com/guides">here</a>.</p><h3>You can create your own dapp using DappStarter in three simple steps:</h3><p><strong>Step 1 : Choose your blockchain</strong></p><p>At the moment, DappStarter supports three blockchains — Ethereum, Harmony, and Klaytn with more blockchains being added frequently.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*R1wa5YfzUhgFtReG" /></figure><p><strong>Step 2: Select your front end framework</strong></p><p>You can choose your favorite frontend framework to power your dapp!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*ciNUg3cFcHROMUdm" /></figure><p><strong>Step 3: Customize features to fit your needs</strong></p><p>The dapp code generated by DappStarter has many out-of-the-box features, including smart contract code, tests for your smart contracts, a web app front-end, and a server-side API. You can leverage these features to build your proxy voting dapp.</p><p><strong>Access Control</strong></p><p>Access Control Block gives you, as a company, granular control over who can manage your contracts and control their options. For instance, if you want to start or stop voting capabilities, you would use this block.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/994/0*mfRt0pOlV-pMy5HC" /></figure><p><strong>File Storage</strong></p><p>Most apps store information, but storage is incredibly expensive on the blockchain so any information stored for a dapp should use decentralized file storage options. For example, if you want to upload the agenda doc, this would be a good fit!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*VYCY0JdVlZYHMOlJ" /></figure><p><strong>Authentication</strong></p><p>For any dapp that deals with voting, authentication is fundamental to ensure only the shareholders are able to vote. With DappStarter, you will not need to worry about implementing an authentication system on your own, this feature will be available very soon.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Xpj9-96k5QVpSUfh" /></figure><p>If you feel there should be more out-of-the-box features, feel free to <a href="https://trycrypto.typeform.com/to/jCIY21">let us know</a>!</p><p>Click on the CREATE<strong> </strong>DAPP<strong> </strong>button. This will point you to a unique Github repository generated on-the-fly for you. You can find your code here. This is going to be your playground!</p><p>You can make modifications according to your business logic in <strong>Contracts/Dapp.sol </strong>file. For instance, you may want to define response options for your voting agenda. Different voting agendas may require different response answers. For example, consider a hypothetical voting agenda “<strong>Do you want Ms. CryptoQueen to be a part of board of directors?</strong>”. The response can be YES, or NO, or ABSTAIN. Another voting agenda can be “<strong>Who do you want to be the CEO — Ms. CryptoKitty or Mr. CryptoDog?</strong>” Here, the response may change — you’d choose between Ms. CryptoKitty and Mr. CryptoDog.</p><p>This is just an example of one of the many subtleties you as a developer would need to cater to.</p><p>Blockchain technology is becoming increasingly important and as the technology continues to evolve, new use cases emerge. Corporate governance, specifically relating to shareholder franchise, is a fantastic use case that has the potential to leverage the auditability and privacy that blockchain can offer.</p><h3>Start building with DappStarter.</h3><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fb2353ff5b6a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/swlh/how-blockchain-could-change-corporate-governance-for-the-better-fb2353ff5b6a">How Blockchain Could Change Corporate Governance for the Better</a> was originally published in <a href="https://medium.com/swlh">The Startup</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[WTF is DeFi?]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://medium.com/trycrypto/wtf-is-defi-cf69ed7283cc?source=rss-44716129d0a2------2"><img src="https://cdn-images-1.medium.com/max/1800/1*jSSLsevEWpd0t8x-1-TSuA.png" width="1800"></a></p><p class="medium-feed-snippet">Lots of hype, very few users. DeFi is blockchain&#x2019;s latest obsession.</p><p class="medium-feed-link"><a href="https://medium.com/trycrypto/wtf-is-defi-cf69ed7283cc?source=rss-44716129d0a2------2">Continue reading on TryCrypto (now Decentology) »</a></p></div>]]></description>
            <link>https://medium.com/trycrypto/wtf-is-defi-cf69ed7283cc?source=rss-44716129d0a2------2</link>
            <guid isPermaLink="false">https://medium.com/p/cf69ed7283cc</guid>
            <category><![CDATA[bitcoin]]></category>
            <category><![CDATA[ethereum]]></category>
            <category><![CDATA[blockchain]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[finance]]></category>
            <dc:creator><![CDATA[Niharika Singh]]></dc:creator>
            <pubDate>Thu, 05 Dec 2019 14:13:57 GMT</pubDate>
            <atom:updated>2020-01-08T13:05:01.826Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[Top 3 Enterprise Blockchains That Will Change The World In 2019]]></title>
            <link>https://niharika3297.medium.com/top-3-enterprise-blockchains-that-will-change-the-world-in-2019-e3d86fa072ea?source=rss-44716129d0a2------2</link>
            <guid isPermaLink="false">https://medium.com/p/e3d86fa072ea</guid>
            <category><![CDATA[business]]></category>
            <category><![CDATA[bitcoin]]></category>
            <category><![CDATA[enterprise-technology]]></category>
            <category><![CDATA[blockchain]]></category>
            <category><![CDATA[technology]]></category>
            <dc:creator><![CDATA[Niharika Singh]]></dc:creator>
            <pubDate>Thu, 29 Aug 2019 13:38:06 GMT</pubDate>
            <atom:updated>2019-08-29T13:43:22.007Z</atom:updated>
            <content:encoded><![CDATA[<p>2019 has been a game changing year for the blockchain industry. Many industrial titans like Facebook, JPMorgan Chase, Walmart, Nasdaq, Starbucks and many more have clearly indicated that they will use blockchain technology to optimize their day-to-day operations.</p><p>Regardless of this buzz, the textbook pundits still believe that the rationale behind blockchain technology is to prevent monopolistic dominance.</p><blockquote><em>Yet here we are talking about the top 3 enterprise blockchains you should definitely know about to keep your business at the top!</em></blockquote><p>Enterprises are <strong>always</strong> on the lookout for improving their solutions to keep up with the consumer driven economy and, also shooting up their revenue at the same time.</p><p>Thanks to the advent of enterprise blockchains; businesses can now optimize their legacy solutions to become more secure, scalable, transparent, robust, and cost-efficient.</p><p>One of the biggest USPs of an enterprise blockchain is to provide the business with the freedom to tailor the specifics of the blockchain according to their own needs. This level of flexibility cannot be offered by any public blockchain at the moment.</p><p>Without any further ado, let’s explore the top 3 enterprise blockchains that have the potential to take your business to the next level.</p><h3>#1. Insolar</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/843/0*hqfNti-fJm9cBFHm.png" /></figure><p>Let’s start the list with the most future-proof enterprise blockchain.</p><p><a href="https://insolar.io/">Insolar</a> is the next-gen enterprise-ready blockchain platform. Insolar has successfully addressed most of the pressing issues that were hampering with mass adoption of blockchain. For example, Insolar is interoperable with other DLTs, it enables on-chain document storage and processing, and also dynamic consensus algorithms can be used on Insolar platform.</p><p>At the moment, Insolar has recorded a performance of 19,500+ TPS on 20 nodes. Unlike other blockchain platforms, Insolar becomes more powerful as more nodes join the network. In other words, Insolar’s performance and security will be enhanced as the number of nodes increases in the network.</p><h3>Here are some cutting edge technical advantages of the Insolar platform:</h3><ul><li>Near-linear scalability</li><li>Best-in-class data protection</li><li>Simplified development</li><li>Interoperability with other DLTs</li><li>Seamless connectivity with existing enterprise software systems</li><li>Supports hybrid networks</li><li>Manages regulatory compliance (GDPR, HER, HIPAA, EMR, and others)</li><li>Easily integratable through HTTP and message-based API</li><li>Continuous evolution of the platform</li></ul><p>According to <a href="https://cryptomiso.com/">Cryptomiso</a>, Insolar has been the most active project on GitHub over the last 12 months and according to <a href="https://coincodecap.com/">Coincodecap</a>, Insolar is the most active project since last three months.</p><p>Insolar is fast growing and has already established itself across multiple industries like energy &amp; utilities sector, supply chain &amp; logistics sector, retail &amp; consumer industry, automotive industry.</p><h3>#2. Hyperledger Fabric</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*xWRESL7Zdt7SeQ2i.png" /></figure><p>Linux Foundation’s and IBM’s <a href="https://www.hyperledger.org/">Hyperledger</a> Fabric is one of the most widely accepted and mature enterprise blockchain solutions available right now.</p><p>Hyperledger Fabric’s modular architecture coupled with large community support makes it a great choice for enterprise-grade cross-industry applications. At the moment, Hyperledger Fabric’s capacity ranges from 3000 TPS to 20,000 TPS.</p><h3>Here are some features of the Hyperledger Fabric:</h3><ul><li>Large and mature community</li><li>Great performance and scalable</li><li>Modular architecture supporting plug-in components such as consensus algorithms</li><li>Smart contracts called ‘chaincodes’ can be hosted using the container technology</li><li>Supports channel technology for confidential transactions</li><li>Complete protection of digital keys and sensitive data</li><li>Allows rich queries over an immutable distributed ledger</li></ul><p>Santander, the Spanish banking giant, has launched real-time trades in Spain which is powered by Hyperledger Fabric. UBS, the Swiss bank, is also working with IBM to create a UBS-backed blockchain trade finance platform. Also, the data-storage company Seagate Technology has collaborated with IBM on Hyperledger Fabric to prevent counterfeiting of electronics.</p><h3>#3. Quorum</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/372/1*YwcAo1F3-WuwyWNyUZUgLQ.png" /></figure><p>JPMorgan’s <a href="https://www.goquorum.com/">Quorum</a> is an open-source Ethereum based enterprise-focused permissioned blockchain. The strongest point of Quorum is that all future Ethereum updates can be easily incorporated with Quorum.</p><p>Quorum’s speed of processing transactions is higher than that of Ethereum. With two nodes running, Quorum can go as high as 140 TPS. It supports private as well as public transactions.</p><h3>Here are some highlights of Quorum:</h3><ul><li>Extension of Ethereum</li><li>100 % privacy of transaction and contract</li><li>Multiple voting-based consensus mechanisms</li><li>Network/Peer permissions management</li><li>Higher performance than Ethereum</li></ul><p>The most known “dApp” on Quorum is the implementation of JPM coin. It has the potential to become a yardstick for the financial institutions.</p><h3>Conclusion</h3><p>Given the rudimentary state of blockchain technology, we have witnessed a high-velocity evolution taking place at a global scale.</p><p>We saw that each blockchain platform has remarkable features of its own. At the end of the day, it is all about which one fits in best with your business. Today, most of the businesses look for flexibility and agility without compromising on quality.</p><p>The future of enterprise blockchain is will focus on high scalability, interoperability, and governance. This is why Insolar may make a future-proof choice (at least for the foreseeable future) for your enterprise.</p><p>Let’s take a moment to get a bigger picture of these three enterprise blockchains by comparing them.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Yld65ndsb8Fx54Jd" /></figure><h4>Such powerful implementations of enterprise blockchains will definitely lead to a larger adoption of the blockchain technology.</h4><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e3d86fa072ea" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>