Creating a blockchain with only browser-based nodes is a very bad idea. Reasons include:
- The only way for browser nodes to connect to each other is the WebRTC protocol. However, you need to bootstrap this using a non-browser-based server (a STUN server) that acts as a rendez-vous point. Every node that joins the network needs to first talk to this non-browser-based node. A network with only browser nodes can’t exist.
- Full nodes need to store the state of the chain (the state of the chain doesn’t exist out of thin air, it needs to be stored somewhere). While the state of a demo chain is a few kilobytes, the state of for example Polkadot and Kusama are several Gigabytes.
- When a browser tab is in the background, the browser slows down all the scripts (see this or this). While it is maybe not strictly impossible to create a full node that exists despite this throttling, it clearly would not work very well, and my guess is many block slots would be missed once you have more than 3 or 4 validators.
- In the context of parachains consensus, it is necessary for specific validator nodes to be reachable by certain other nodes. In other words, not everything is done by gossiping. It is not really possible to guarantee that when the node is within a browser.
As a small toy it would work. In the real world, it wouldn’t.