BABEL-NODE.JS(1)
β¨ NAME β¨
babel-node.js β okay bestie, picture the Node.js CLI, right? Now picture it with main character energy. It works exactly the same as the Node.js CLI, except it has the added benefit of compiling with Babel presets and plugins before running it. That's the whole serve. π
And yes, this is a section 1 manpage β User Commands β so you know it's a real command you can just run. π«Ά
πΈ SYNOPSIS πΈ
babel-node [options] [ -e script | script.js ] [arguments]
Like, that's it. That's the shape of every invocation. Options first if you want 'em, then either a script via -e or a script.js file, then whatever arguments you're passing through. Simple. Elegant. Ate. π₯
π OPTIONS π
-e,--eval [script]β Evaluate script. You hand it code, it runs the code. No file required. β¨--no-babelrcβ Specify whether or not to use.babelrcand.babelignorefiles. Yes, this is the switch that decides if those files get a seat at the table. π¦-r,--require [module]β Require module. Pulls it in before anything else gets going.-p,--print [code]β Evaluate code and print the result. It's giving "just show me the output, bestie." π-o,--only [globs]β A comma-separated list of glob patterns to compile. Only these. Nothing else. Gatekeeping, but make it config. π-i,--ignore [globs]β A comma-separated list of glob patterns to skip compiling. The opposite vibe of--only, and no, they are not the same flag, don't do that. π-x,--extensions [extensions]β List of extensions to hook into. The default lineup is[.es6,.js,.es,.jsx,.mjs]β yes, all five, that's the squad. π--config-file [path]β Path to the Babel config file to use. Defaults to working directorybabel.config.js. So if you say nothing, that's the one it goes looking for. π--env-name [name]β The name of the'env'to use when loading configs and plugins. Defaults to the value ofBABEL_ENV, or elseNODE_ENV, or else'development'. Yes, it's a fallback chain β three deep. It's got layers. π§--root-mode [mode]β The project-root resolution mode. One of'root'(the default),'upward', or'upward-optional'. Three choices, pick your fighter. β-w,--plugins [string]β the manpage gives no description here, bestie. It literally just says[string]and moves on. No lore provided. π-b,--presets [string]β same situation fr fr, no description in the docs, just[string]. We report, we don't invent. π-V,--versionβ output the version number. Classic. Does exactly what it says. π-h,--helpβ display help for command. Your little escape hatch when the vibes get confusing. π
ngl bestie, if you're ever lost, -h is right there and it will never judge you. π«Ά
And that's the whole page! This one comes to you from babel-node.js 7.20.15+ds1+~cs... and it was dated February 2025 β so if you're reading this way later, just know the version and the date, okay? mwah, go compile something cute. πβ¨
π¦ where this page comes from
- debian trixie: node-babel7 7.20.15+ds1+~cs214.269.168-8 Β· MIT
- ubuntu questing: node-babel7 7.20.15+ds1+~cs214.269.168-8
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms