Bazel
ELI5 - The Vibe Check
Bazel is Google's build tool for when your codebase gets so big that just running an install and build script stops being good enough. It figures out exactly which files changed, builds only what depends on them, and can reuse cached results from anyone else who already built the exact same thing, which is how companies with millions of lines of code still get fast builds.
Real Talk
Bazel is an open-source build and test tool, originally built at Google, that uses a declarative dependency graph to enable incremental, reproducible, and highly parallelized builds across large multi-language monorepos. It supports remote caching and remote execution, so builds can scale across a fleet of machines instead of a single laptop.
Show Me The Code
# BUILD.bazel
load("@rules_js//js:defs.bzl", "js_library")
js_library(
name = "utils",
srcs = glob(["src/**/*.ts"]),
deps = ["//packages/shared:types"],
)
When You'll Hear This
"We moved the monorepo to Bazel once the build started taking 20 minutes on every CI run." / "Bazel's hermetic builds mean the same target produces the same output no matter who runs it."
Related Terms
Monorepo Tools
Monorepo tools help you manage a massive codebase where everything — frontend, backend, shared libraries — lives in one repository without losing your mind
Nx
Nx is like a smart contractor for your monorepo.
Remote Caching
Remote caching means if a teammate already built the exact same code with the exact same inputs an hour ago, your machine doesn't rebuild it, it just downl...
Reproducible Builds
A reproducible build means if ten different people, on ten different computers, build your code from the exact same source, they all get byte-for-byte iden...
Turborepo
Turborepo makes your monorepo fast by figuring out which things need to rebuild and which can be skipped. Change the homepage?