@housekit/orm 0.1.4 → 0.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +26 -0
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  **The high-performance, type-safe ClickHouse ORM for Node.js and Bun.**
4
4
 
5
+ > ⚠️ **Public Beta**: This package is currently in public beta. Feedback is highly appreciated as we polish the API for v1.0.
6
+
5
7
  HouseKit ORM is a modern database toolkit designed specifically for ClickHouse. It bridges the gap between ergonomic developer experiences and the extreme performance requirements of high-volume OLAP workloads.
6
8
 
7
9
  [![npm version](https://img.shields.io/npm/v/@housekit/orm.svg)](https://www.npmjs.com/package/@housekit/orm)
@@ -180,6 +182,30 @@ const usersWithData = await db.query.users.findMany({
180
182
  // [{ id: 1, name: 'Alice', posts: [{ title: '...', ... }], profile: { bio: '...' } }]
181
183
  ```
182
184
 
185
+ ### Advanced Relational Engine
186
+ HouseKit's relational API is optimized for ClickHouse:
187
+ - **Filtered Relations**: Where clauses in `with` blocks are executed server-side using `groupUniqArrayIf`.
188
+ - **Nested Pagination**: Control the size of related collections with `limit` and `offset` directly in the relation config.
189
+ - **Smart Deduplication**: Merges results in-memory to handle row multiplication from complex joins.
190
+
191
+ ---
192
+
193
+ ## 🛠 SQL Utilities
194
+
195
+ ### Dynamic Queries with `sql.join`
196
+ Easily build complex queries by joining SQL fragments with separators.
197
+
198
+ ```typescript
199
+ const conditions = [
200
+ eq(users.active, true),
201
+ gte(users.age, 18)
202
+ ];
203
+
204
+ const query = db.select()
205
+ .from(users)
206
+ .where(sql.join(conditions, sql` AND `));
207
+ ```
208
+
183
209
  ---
184
210
 
185
211
  ## 🔍 Specialized ClickHouse Joins
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@housekit/orm",
3
- "version": "0.1.4",
3
+ "version": "0.1.6",
4
4
  "description": "Type-safe ClickHouse ORM with modern DX and ClickHouse-specific optimizations. Features Turbo Mode (RowBinary), full engine support, and advanced query capabilities.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",