Posts
JavaScript Basics: Locate Module Resources with File URLs
A relative filesystem path normally depends on the process working directory. An ES module can instead resolve a resource beside its own source using new URL(relative, …
October 19, 2026
JavaScript Basics: Consume Asynchronous Sequences with for await
An asynchronous iterator supplies its next result through a promise. for await...of waits for each result, making it useful for paginated data and sequential processing. Unlike a …
October 19, 2026
JavaScript Basics: Check Own Properties and Build Safe Dictionaries
Object lookup normally follows a prototype chain. That is useful for methods, but surprising when an object represents a dictionary of user-supplied labels. Object.hasOwn() …
October 19, 2026
Linux Basics: Read Text with Bash read and mapfile
Preserve spaces, split a simple record, or load a short list into an array. Choose the input method that matches your text format. These examples were tested on Linux with GNU Bash …
October 19, 2026
Linux Basics: Parse Bash Options with getopts
Give small scripts clear flags without manually shifting every argument. Start with short options, then handle input errors and remaining filenames. These examples were tested on …
October 19, 2026
Linux Basics: Match Text with Bash case Patterns
A case statement makes a small text classifier readable. Patterns match strings directly; these examples do not search the filesystem. These examples were tested on Linux with GNU …
October 19, 2026
Linux Basics: Format Bash Output with printf
Predictable output helps both people and downstream tools. Keep the format string fixed, then pass values as quoted arguments. These examples were tested on Linux with GNU Bash …
October 19, 2026
Linux Basics: Clean Up Bash Temporary Files with Traps
Register cleanup just after creating temporary state. These examples remove only files they created, and use rmdir rather than recursive deletion. These examples were tested on …
October 19, 2026
SQLite Basics: Protect Rows with NOT NULL, CHECK, and UNIQUE
Constraints put basic validation next to the data. These isolated examples use INSERT OR IGNORE to demonstrate rejected rows without stopping the teaching runner. Real applications …
October 19, 2026
SQLite Basics: Keep Related Rows Consistent with Foreign Keys
A foreign key links a child row to a valid parent. Enable enforcement on every connection before starting a transaction. Each example explicitly enables it and uses disposable …
October 19, 2026