Key formatting library for generating formatted keys from function arguments with placeholders (positional, property paths, pre-defined values). Current version 0.0.2. Minimal API surface with a single function. Differentiates from template engines by tight integration with function argument patterns, using {0}, {this.foo}, {1.bar} syntax. No updates since 2015; considered feature-complete but unmaintained.
npm install keyfNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to create a formatter with a template string and pre-defined values, then call it with a context and arguments.
Pass all static mappings in the options object when creating the formatter
Always invoke the formatter with `formatter.call(context, arguments)`
Use the `arguments` object directly (or an array-like) when calling the formatter
Use `const keyf = require('keyf')` or `import keyf from 'keyf'`Pass pre-defined values as second argument to keyf(), e.g. keyf('{_user_}', { _user_: 'alice' })No dependency data recorded yet.