QLMapper (v1.1.2) generates nested objects from SQL query result rows by grouping columns with a prefix convention (e.g., __user__name). It simplifies mapping flat join outputs into structured objects, especially for PostgreSQL queries. Unlike manual mapping, it reduces boilerplate and supports custom prefixes and depth handling. Maintenance is low; no recent updates since initial release. Release cadence is sparse.
npm install qlmapperNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows how to map a flat SQL row with prefixed columns into a nested object using QLMapper.
Pass custom prefix as third argument: QLMapper(row, groups, {prefix: '##'})Ensure all columns you intend to group follow the prefix convention.
Install @types/qlmapper if community provides, or declare module manually.
Always pass groups as an array: e.g., ['user', 'address'].
Use `import QLMapper from 'qlmapper'` or `const QLMapper = require('qlmapper').default`.Ensure first argument is an object with string keys.
Use bracket notation: result['__user__name'] or ensure mapping is complete.
No dependency data recorded yet.