Registry / http-networking / micromist

micromist

JSON →
library1.1.0jsnpmunverified

micromist is a JavaScript package designed for parsing command-line arguments in Node.js environments. As indicated by its name and `v1.1.0` (last updated 8 years ago), it offers a highly minimal API, primarily exporting a single function that takes `process.argv` and returns a parsed object. The library's core differentiator is its simplicity, aiming to provide basic argument parsing without the overhead or extensive features found in more comprehensive alternatives. Due to its long-abandoned status, there is no active release cadence, and it remains a CommonJS-only module, lacking native support for ECMAScript Modules (ESM). Developers should consider this if building modern applications or requiring advanced parsing capabilities.

npm install micromist
INSTALL
IMPORT
SIG · MICROMIST
M
micromist
http-networkingjavascriptv1.1.0
Install
Import
Disk
Pass rate
0/ 6
Env Coverage0 / 6
glibc
1822
musl
1822
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 18226 runs
build_error
glibc
node 18226 runs
build_error
Code
Verified usage

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

micromist
const micromist = require('micromist');
import micromist from 'micromist';
micromist is a CommonJS-only module, last published 8 years ago. ESM imports will fail without a transpiler or bundler.
micromist
const parseArgs = require('micromist'); const args = parseArgs(process.argv.slice(2));
import { parseArgs } from 'micromist';
The default export is the parsing function. There are no named exports. Pass `process.argv.slice(2)` to exclude 'node' and the script name.

Demonstrates basic parsing of command-line arguments including flags and values using the CommonJS `require` syntax.

const micromist = require('micromist'); // Simulate command-line arguments: node myscript.js --name John --age 30 -f --verbose // In a real scenario, process.argv would be used directly. const simulatedArgv = ['node', 'myscript.js', '--name', 'John', '--age', '30', '-f', '--verbose']; // Slice the array to remove 'node' and the script path const args = micromist(simulatedArgv.slice(2)); console.log('Parsed arguments:', args); console.log('Name:', args.name); // Expected: 'John' console.log('Age:', args.age); // Expected: 30 (micromist might auto-cast numbers) console.log('Force flag:', args.f); // Expected: true console.log('Verbose flag:', args.verbose); // Expected: true console.log('Remaining arguments:', args._); // Expected: [] (arguments without flags)
Debug
Known issues
breakingThe micromist package is unmaintained and was last updated 8 years ago (v1.1.0). It does not receive security patches, bug fixes, or feature updates. Using abandoned libraries can introduce significant security vulnerabilities and compatibility issues with newer Node.js versions or ecosystems.
fix
Consider migrating to actively maintained and widely adopted argument parsing libraries such as `minimist`, `yargs`, or `commander.js` for better security, features, and community support.
affects: >=1.0.0
gotchaAs an unmaintained and minimal parser, `micromist` might not correctly handle complex argument patterns, type coercion (e.g., arrays, booleans explicitly), or dash-separated arguments beyond basic flags. It lacks robust option configuration.
fix
Manually inspect and sanitize all parsed arguments. For more complex CLI requirements, use a feature-rich and maintained parser like `yargs` or `commander.js` which offer explicit type definitions, aliases, defaults, and validation.
affects: >=1.0.0
gotchaSimilar minimal argument parsers (e.g., `minimist` versions <=1.2.5) have been affected by prototype pollution vulnerabilities. While `micromist` hasn't had a public CVE, its unmaintained status means any such vulnerability would remain unpatched, posing a significant security risk when processing untrusted user input.
fix
Avoid using `micromist` if your application processes untrusted command-line arguments directly. If migration isn't immediately possible, implement strict input validation and sanitization on all parsed arguments to prevent unexpected property assignments or code execution.
affects: >=1.0.0
Errors
Common errors & fixes
TypeError: micromist is not a function
Attempting to use `micromist` as a named export or calling it incorrectly, or trying to `import` it as an ESM module when the environment is configured for CJS or the package is CJS-only.
fix
Ensure you are using `const micromist = require('micromist');` and then calling `micromist(argsArray);`. Do not use `import` statements if your project or environment does not transpile CJS modules to ESM.
UnhandledPromiseRejectionWarning: TypeError: micromist is not a function (in ESM context)
Attempting to `import micromist from 'micromist'` in an ESM-enabled Node.js project without proper interop configuration or when the package itself is strictly CJS.
fix
As `micromist` is a CJS-only package, explicit `require` might be needed in some ESM contexts via `import { createRequire } from 'module'; const require = createRequire(import.meta.url); const micromist = require('micromist');` or revert to a CJS entry point.
Upgrade
Version history
1.1.0latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
7 hits · last 30 days
node
6
Resources
micromist — npm install micromist · libregistry