Glossary coding Term Page

Hash Router

Route by watching `location.hash` and swapping views without reloads.

hash-router #routing#javascript
Korean version

Aliases

hash-based routerclient hash router

Related Concepts

Core Idea

A hash router listens to hashchange, parses the fragment after #, and renders the matching component. Because hashes never hit the server, it works everywhere from static hosting to prototypes without extra config.

Why It Matters Here

Mathbong introduces hash routers first so readers see routing fundamentals before layering on History API helpers or navigation guards. That foundation keeps the series’ routing demos framework-agnostic.

Posts Mentioning This Concept