@molecule/api-resource-follow 1.0.6 → 1.0.8

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.
package/README.md CHANGED
@@ -3,20 +3,20 @@ AUTO-GENERATED — DO NOT EDIT THIS FILE.
3
3
  Generated by `mlcl sync-docs` from the package's src/index.ts JSDoc + mlcl/registry.json.
4
4
  Edits here are overwritten on the next commit (molecule's pre-commit hook regenerates).
5
5
  To change this document, edit the module-level JSDoc in src/index.ts.
6
- Generated: 2026-10-16T00:32:23.444Z
6
+ Generated: 2026-10-17T20:52:29.035Z
7
7
  -->
8
8
 
9
9
  # @molecule/api-resource-follow
10
10
 
11
- > **Auto-generated, AI-first package reference** for the [molecule.dev](https://molecule.dev) ecosystem.
12
- > It is written to be read by coding agents as much as by people, and is generated from this
13
- > package's source — edit `src/index.ts` JSDoc, not this file.
14
-
15
11
  Follow/unfollow resource for molecule.dev.
16
12
 
17
13
  Polymorphic follow system for users or any resource type. Supports
18
14
  followers list, following list, and follow status checks.
19
15
 
16
+ > **Auto-generated, AI-first package reference** for the [molecule.dev](https://molecule.dev) ecosystem.
17
+ > It is written to be read by coding agents as much as by people, and is generated from this
18
+ > package's source — edit `src/index.ts` JSDoc, not this file.
19
+
20
20
  ## Quick Start
21
21
 
22
22
  ```typescript
@@ -325,8 +325,11 @@ Peer dependencies:
325
325
  from `@molecule/app-http` normalizes this envelope (pass it the whole HttpResponse), so
326
326
  the rows come back; reading the response as a bare array — or `res.data` alone (which is
327
327
  the envelope) — yields an EMPTY list.
328
- Table: `src/__setup__/follows.sql` creates the single `follows` table. An
329
- mlcl-scaffolded API replays `__setup__/*.sql` automatically on migrate;
328
+ A scaffold that lists this package already has this table: its `__setup__` SQL is copied
329
+ into the app at create time and replayed on every boot, so do not copy it into
330
+ `api/migrations/` yourself — only a package added after the scaffold needs that.
331
+ `src/__setup__/follows.sql` creates the single `follows` table. An
332
+ mlcl-scaffolded API replays `__setup__/*.sql` on migrate (a `CREATE TABLE IF NOT EXISTS`, so a table the app's own migrations already create keeps only its own columns: ALTER in the ones it lacks);
330
333
  anywhere else run it once — nothing at runtime creates it.
331
334
 
332
335
  The follower is ALWAYS the authenticated user: handlers read
package/dist/index.d.ts CHANGED
@@ -23,8 +23,11 @@
23
23
  * from `@molecule/app-http` normalizes this envelope (pass it the whole HttpResponse), so
24
24
  * the rows come back; reading the response as a bare array — or `res.data` alone (which is
25
25
  * the envelope) — yields an EMPTY list.
26
- * Table: `src/__setup__/follows.sql` creates the single `follows` table. An
27
- * mlcl-scaffolded API replays `__setup__/*.sql` automatically on migrate;
26
+ * A scaffold that lists this package already has this table: its `__setup__` SQL is copied
27
+ * into the app at create time and replayed on every boot, so do not copy it into
28
+ * `api/migrations/` yourself — only a package added after the scaffold needs that.
29
+ * `src/__setup__/follows.sql` creates the single `follows` table. An
30
+ * mlcl-scaffolded API replays `__setup__/*.sql` on migrate (a `CREATE TABLE IF NOT EXISTS`, so a table the app's own migrations already create keeps only its own columns: ALTER in the ones it lacks);
28
31
  * anywhere else run it once — nothing at runtime creates it.
29
32
  *
30
33
  * The follower is ALWAYS the authenticated user: handlers read
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgEG;AAEH,cAAc,wBAAwB,CAAA;AACtC,cAAc,oBAAoB,CAAA;AAClC,cAAc,qBAAqB,CAAA;AACnC,cAAc,wBAAwB,CAAA;AACtC,cAAc,aAAa,CAAA;AAC3B,cAAc,cAAc,CAAA;AAC5B,cAAc,YAAY,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmEG;AAEH,cAAc,wBAAwB,CAAA;AACtC,cAAc,oBAAoB,CAAA;AAClC,cAAc,qBAAqB,CAAA;AACnC,cAAc,wBAAwB,CAAA;AACtC,cAAc,aAAa,CAAA;AAC3B,cAAc,cAAc,CAAA;AAC5B,cAAc,YAAY,CAAA"}
package/dist/index.js CHANGED
@@ -23,8 +23,11 @@
23
23
  * from `@molecule/app-http` normalizes this envelope (pass it the whole HttpResponse), so
24
24
  * the rows come back; reading the response as a bare array — or `res.data` alone (which is
25
25
  * the envelope) — yields an EMPTY list.
26
- * Table: `src/__setup__/follows.sql` creates the single `follows` table. An
27
- * mlcl-scaffolded API replays `__setup__/*.sql` automatically on migrate;
26
+ * A scaffold that lists this package already has this table: its `__setup__` SQL is copied
27
+ * into the app at create time and replayed on every boot, so do not copy it into
28
+ * `api/migrations/` yourself — only a package added after the scaffold needs that.
29
+ * `src/__setup__/follows.sql` creates the single `follows` table. An
30
+ * mlcl-scaffolded API replays `__setup__/*.sql` on migrate (a `CREATE TABLE IF NOT EXISTS`, so a table the app's own migrations already create keeps only its own columns: ALTER in the ones it lacks);
28
31
  * anywhere else run it once — nothing at runtime creates it.
29
32
  *
30
33
  * The follower is ALWAYS the authenticated user: handlers read
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@molecule/api-resource-follow",
3
- "version": "1.0.6",
3
+ "version": "1.0.8",
4
4
  "description": "Follow/unfollow users or any resource with polymorphic targeting",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",