Build A Blockchain In Javascript

Code out your very own Blockchain and decentralized network in the JavaScript programming language.

Last updated 2022-01-10 | 4.7

- Have your own
- fully functional
- blockchain prototype.
- Learn how the code behind blockchain technology functions.
- Learn why blockchain technology is a very secure means of storing data.

What you'll learn

Have your own
fully functional
blockchain prototype.
Learn how the code behind blockchain technology functions.
Learn why blockchain technology is a very secure means of storing data.
Learn how a decentralized blockchain network works.

* Requirements

* Basic knowledge of JavaScript.
* NodeJS installed.
* The entire course is done on a Mac - if you have a Windows PC
* you will be responsible for adapting the information to that operating system.

Description

In this course you will be building your very own blockchain and decentralized blockchain network by using the JavaScript programming language.  By building your own blockchain, you will learn how blockchain technology works under-the-hood, how decentralized blockchain networks function, how the code behind these technologies work, and why blockchain is such a secure and valuable technology.

The blockchain that you build in this course will have all of the following features:

  • A proof of work algorithm to secure the network.
  • Hashing algorithms to secure the data within the blockchain.
  • The ability to mine (create) new blocks that contain data.
  • The ability to create transactions and store them in blocks.
  • An API/server that will be used to interact with the blockchain from the internet.
  • It will be hosted on a decentralized blockchain network.
  • A consensus algorithms to verify that the network nodes have valid data and are synchronized.
  • A broadcasting system to keep the data in the blockchain network synchronized.
  • Many other awesome features!...

When you have completed this course you will have built out your own blockchain prototype in code.  You will have a thorough understanding of how blockchain technology actually works and why this technology is so secure and valuable.  You will also have a deep understanding of how decentralized blockchain networks function and why decentralization is such an important feature for securing the blockchain. The whole process of storing, securing, and validating data/transactions on the blockchain will become very clear.

Who this course is for:

  • Anyone who wants to build their own Blockchain Prototype in code.
  • Anyone who wants to learn how Blockchain Technology works under-the-hood.
  • Anyone who wants to understand how the "decentralization" of blockchain actually works.
  • Anyone who wants to gain a better understanding of why Blockchain Technology is valuable.
  • Anyone who wants to learn how the code behind Blockchain Technology works.

Course content

8 sections • 75 lectures

Course Introduction Preview 02:57

What You Will Learn In This Course Preview 03:03

What Is A Blockchain? Preview 05:26

Environment Setup Preview 04:02

Project Source Code Preview 01:10

Project Source Code Link Article Preview 00:19

Blockchain Introduction Preview 01:44

Constructor Function Explanation Preview 07:57

Prototype Object Explanation Preview 06:07

Blockchain Constructor Function Preview 03:41

Create New Block Method Preview 09:35

Testing Create New Block Method Preview 05:59

Get Last Block Method Preview 01:03

Create New Transaction Method Preview 06:38

Testing Create New Transaction Method Preview 12:20

SHA256 Hashing Preview 05:41

Hash Block Method Preview 05:42

Testing Hash Block Method Preview 05:00

What Is A Proof Of Work? Preview 09:23

Proof Of Work Method Preview 05:50

Testing Proof Of Work Method Preview 08:45

Creating A Genesis Block Preview 03:31

Section 1 Wrap-Up Preview 00:43

Blockchain Source Code Preview 00:18

Building An API - Introduction Preview 01:50

Setting Up ExpressJS Preview 03:39

Building The API Foundation Preview 03:18

Installing Postman & Body-Parser Preview 12:53

Building The "GET /blockchain" Endpoint Preview 04:00

Building The "POST /transaction" Endpoint Preview 07:53

Building The "GET /mine" Endpoint Preview 14:33

Testing The New Endpoints Preview 12:49

Decentralized Blockchain Network - Introduction Preview 02:33

Creating Multiple Nodes Preview 11:43

Testing The Nodes Preview 03:58

Adding The Current Node's Url Preview 03:09

New Endpoints Outline Preview 08:30

Building "POST /register-and-broadcast-node" Endpoint - Part 1 Preview 11:10

Building "POST /register-and-broadcast-node" Endpoint - Part 2 Preview 07:00

Building "POST /register-node" Endpoint Preview 06:39

UPDATE: Installing the "request" library Preview 00:24

Testing "POST /register-node" Endpoint Preview 05:47

Building "POST /register-nodes-bulk" Endpoint Preview 08:46

Testing "POST /register-nodes-bulk" Endpoint Preview 04:25

Testing All Network Endpoints Preview 12:46

Synchronizing The Network - Introduction Preview 03:10

Transactions Introduction Preview 03:07

Refactoring Create Transaction Method Preview 05:18

Building "POST /transaction/broadcast" Endpoint Preview 09:05

Refactoring "POST /transaction" Endpoint Preview 05:18

Testing Transaction Endpoints Preview 08:03

Updating Mining Information Preview 03:30

Updating Mining Endpoint Preview 10:54

Building "POST /receive-new-block" Endpoint Preview 09:04

Testing New Endpoints Preview 17:49

Consensus Introduction Preview 04:26

Chain Is Valid Method Preview 16:10

Testing Chain Is Valid Method Preview 10:42

Building "GET /consensus" Endpoint Preview 20:23

Testing "GET /consensus" Endpoint Preview 08:08

Block Explorer Introduction Preview 02:27

Block Explorer Endpoints Outline Preview 03:42

Get Block Method Preview 04:39

Building "GET /block/:blockHash" Endpoint Preview 06:38

Get Transaction Method Preview 06:09

Building "GET /transaction/:transactionId" Endpoint Preview 06:59

Get Address Data Method Preview 07:51

Building "GET /address/:address" Endpoint Preview 09:32

Adding The Block Explorer File Preview 05:52

Block Explorer File Source Code Preview 00:01

Block Explorer File Explanation Preview 04:35

Testing The Block Explorer! Preview 10:32