@effectstream/db-emulator 0.100.20 → 0.100.22

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@effectstream/db-emulator",
3
- "version": "0.100.20",
3
+ "version": "0.100.22",
4
4
  "license": "MIT",
5
5
  "homepage": "https://effectstream.github.io/docs/",
6
6
  "repository": {
package/patch-emulator.ts CHANGED
@@ -1,5 +1,9 @@
1
1
  import { run } from "effection";
2
- import { createDynamicTables } from "@effectstream/db";
2
+ import {
3
+ createDynamicTables,
4
+ detectCapabilities,
5
+ selectViewStrategy,
6
+ } from "@effectstream/db";
3
7
  import type { Client } from "pg";
4
8
  import { applyMigrations } from "@effectstream/db/version";
5
9
  import type { SyncProtocolWithNetwork } from "@effectstream/config";
@@ -61,6 +65,9 @@ export async function standAloneApplyMigrations(
61
65
  },
62
66
  );
63
67
 
68
+ const capabilities = await detectCapabilities(db as any);
69
+ const viewStrategy = selectViewStrategy(capabilities);
70
+
64
71
  await run(function* () {
65
72
  return yield* createDynamicTables(
66
73
  {
@@ -72,6 +79,7 @@ export async function standAloneApplyMigrations(
72
79
  0,
73
80
  db,
74
81
  config as any,
82
+ viewStrategy,
75
83
  );
76
84
  });
77
85
  const migrations = migrationTable;