ini-simple-parser is a lightweight, performant, and configurable library designed for parsing INI (initialization file) format strings in JavaScript and TypeScript environments. It is currently at version 1.0.1, indicating a stable initial release. The library focuses on simplicity and speed, offering options to infer data types such as booleans, nulls, and numbers, as well as automatic removal of wrapping quotes and inline comments. This differentiates it by providing a clean, configurable API for common INI parsing needs without excessive complexity, making it suitable for applications requiring straightforward configuration file handling. Its release cadence is not explicitly stated but typically for such a utility, updates would address bugs or minor feature enhancements rather than frequent major overhauls.
npm install ini-simple-parserVerified import paths — ran on the pinned version, not inferred.
Demonstrates parsing a complex INI string with all available inference options enabled, showing automatic type conversion and comment stripping.
Pass an options object to the `parse` function, e.g., `parse(input, { inferBooleans: true, inferNumbers: true, inferStrings: true })`.To remove inline comments, use `parse(input, { inlineComments: true })`.For CommonJS, access the default export: `const parse = require('ini-simple-parser').default;` or migrate to ESM imports: `import parse from 'ini-simple-parser';`.Enable specific inference options when calling `parse`. For example, `parse(input, { inferBooleans: true, inferNulls: true, inferNumbers: true })`.No dependency data recorded yet.