{"repo":"craigmichaelmartin/pure-orm","free":true,"listed":false,"github":"https://github.com/craigmichaelmartin/pure-orm","clone":"git clone https://github.com/craigmichaelmartin/pure-orm.git","description":"A pure ORM for writing native SQL queries yielding pure business objects","language":"TypeScript","stars":396,"topics":["nodejs","sql","postgresql","orm","node-postgres","pg-promise","toolkit","database","javascript","object-relational-mapper"],"license":"MIT","category":"databases-storage","readme_excerpt":"PureORM Installation What is PureORM? PureORM is a lightweight ORM for mapping the relational result rows of a database driver query to properly structured (nested) pure instances of your business object classes. It's purpose - and guiding principle - is to allow you to write native , unobstructed SQL (not niche library-specific ORM wrapper APIs) and receive back properly structured/nested pure business objects (not database-connected stateful objects). What does this mean? This means you can just write SQL like this: ...And for the result data id name id personId employerId startDate endDate id name --- -------- --- -------- ---------- ---------- ---------- --- ----------- 55 John Doe 277 55 17 2020-01-01 2020-12-31 17 Good Corp 55 John Doe 278 55 26 2021-01-01 2021-12-31 26 Better Corp ...Rather than getting flat, collided result objects: ...You get properly structured/nested, pure objects like this: ...Where these objects are instantiations of classes you define. So the above is our (not shown) Person class, which has a jobs field pointing to our (not shown) Jobs collection class, which has individual (not shown) Job classes, which have a employer field pointing to our (not shown) Employer classes. Each of these classes is defined by us, and can contain custom business logic. (Check out the full example lower down to see these!) How does PureORM compare with traditional ORMs? PureORM contrasts with tradtional ORMs in two important ways: 1. PureORM is purely the \"orm\" (obje","default_branch":null,"files":null,"tree":[],"storefront":"/r/craigmichaelmartin","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/craigmichaelmartin/pure-orm/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}