Registry / testing / tower-of-babel

tower-of-babel

JSON →
library1.0.0jsnpmunverified

A Node.js workshopper tutorial that teaches ES6 features through interactive exercises. Version 1.0.0 (last release circa 2015) is stable and uses Babel 6 with the es2015 preset. It is designed for offline command-line learning, with each exercise requiring the user to write code that passes a test. Differentiators: focuses exclusively on ES6 transpilation with Babel, as opposed to general ES6 tutorials. No longer actively maintained; superseded by modern environments with native ES6 support.

npm install tower-of-babel
INSTALL
IMPORT
SIG · TOWER-OF-BABEL
T
tower-of-babel
testingjavascriptv1.0.0
Install
—
Import
—
Disk
—
Pass rate
0/ 6
Env Coverage0 / 6
glibc
18–22
musl
18–22
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18–226 runs
build_error
glibc
node 18–226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Default import pattern
✓ import fs from 'fs';
✗ const fs = require('fs');
ES6 import syntax is used throughout the exercises.
Named import pattern
✓ import { readFile } from 'fs';
✗ const readFile = require('fs').readFile;
ES6 named imports are encouraged.
Arrow function
✓ const add = (a, b) => a + b;
✗ function add(a, b) { return a + b; }
Arrow functions are a key ES6 feature taught.

Sets up a new project with ESLint, Babel, and starts the Tower of Babel tutorial.

mkdir tower-of-babel-solutions && cd tower-of-babel-solutions && npm init -y && npm i tower-of-babel && npm i babel-cli babel-preset-es2015 && echo '{ "presets": ["es2015"] }' > .babelrc && ./node_modules/tower-of-babel/tower-of-babel.js
tower-of-babel --version
Debug
Known issues
deprecatedTower of Babel uses Babel 6 and is no longer maintained. Modern environments support ES6 natively.
fix
Consider using native ES6 or a modern tutorial.
affects: *
getting errorRequires Node.js version 4 or lower. May fail on newer Node versions due to changes in module resolution.
fix
Use an older Node.js version (e.g., 4.x) or Docker to run the tutorial.
affects: >=10.0.0
gotchaThe .babelrc file must have presets set to es2015 for Babel 6. Babel 7 uses @babel/preset-env.
fix
For Babel 7, install @babel/cli, @babel/preset-env and set { "presets": ["@babel/preset-env"] } in .babelrc.
affects: >=1.0.0
Errors
Common errors & fixes
Error: Cannot find module 'babel-preset-es2015'
The required babel-preset-es2015 is not installed.
fix
Run 'npm install babel-preset-es2015' inside the project directory.
sh: ./node_modules/.bin/tower-of-babel: No such file or directory
The tower-of-babel package is not installed or the path is incorrect.
fix
Ensure tower-of-babel is in node_modules: run 'npm install tower-of-babel' from the project root.
Error: Module version mismatch. Expected 50, got 48.
Babel is not compatible with the installed Node.js version.
fix
Use Node.js version 4.x or upgrade to Babel 7 with a compatible Node version.
Upgrade
Version history
1.0.0latest on npm
Audit
Dependencies
babel-clirequiredRequired to transpile ES6 code in exercises
babel-preset-es2015requiredPreset needed for ES6 transpilation
Agent activity
10 hits · last 30 days
node
10
Resources
tower-of-babel — npm install tower-of-babel · libregistry