@electric-sql/pglite-pgvector 0.0.1

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 +29 -0
  2. package/package.json +64 -0
package/README.md ADDED
@@ -0,0 +1,29 @@
1
+ # @electric-sql/pglite-pgvector
2
+
3
+ [pgvector](https://github.com/pgvector/pgvector/) extension for [PGlite](https://pglite.dev).
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install @electric-sql/pglite-pgvector
9
+ ```
10
+
11
+ ## Usage
12
+
13
+ ```typescript
14
+ import { PGlite } from '@electric-sql/pglite'
15
+ import { vector } from '@electric-sql/pglite-pgvector'
16
+
17
+ const pg = new PGlite({
18
+ extensions: {
19
+ vector,
20
+ },
21
+ })
22
+
23
+ await pg.exec('CREATE EXTENSION IF NOT EXISTS vector;')
24
+
25
+ ```
26
+
27
+ ## License
28
+
29
+ Apache-2.0
package/package.json ADDED
@@ -0,0 +1,64 @@
1
+ {
2
+ "name": "@electric-sql/pglite-pgvector",
3
+ "version": "0.0.1",
4
+ "description": "pgvector extension for PGlite",
5
+ "author": "Electric DB Limited",
6
+ "homepage": "https://pglite.dev",
7
+ "license": "Apache-2.0",
8
+ "keywords": [
9
+ "postgres",
10
+ "sql",
11
+ "database",
12
+ "wasm",
13
+ "pglite",
14
+ "pgvector"
15
+ ],
16
+ "private": false,
17
+ "publishConfig": {
18
+ "access": "public"
19
+ },
20
+ "type": "module",
21
+ "main": "./dist/index.cjs",
22
+ "module": "./dist/index.js",
23
+ "types": "./dist/index.d.ts",
24
+ "exports": {
25
+ ".": {
26
+ "import": {
27
+ "types": "./dist/index.d.ts",
28
+ "default": "./dist/index.js"
29
+ },
30
+ "require": {
31
+ "types": "./dist/index.d.cts",
32
+ "default": "./dist/index.cjs"
33
+ }
34
+ }
35
+ },
36
+ "files": [
37
+ "dist"
38
+ ],
39
+ "repository": {
40
+ "type": "git",
41
+ "url": "git+https://github.com/electric-sql/pglite.git",
42
+ "directory": "packages/pglite-pgvector"
43
+ },
44
+ "scripts": {
45
+ "build": "tsup && tsx scripts/bundle-wasm.ts",
46
+ "check:exports": "attw . --pack --profile node16",
47
+ "lint": "eslint ./src ./tests --report-unused-disable-directives --max-warnings 0",
48
+ "format": "prettier --write ./src ./tests",
49
+ "typecheck": "tsc",
50
+ "stylecheck": "pnpm lint && prettier --check ./src ./tests",
51
+ "test": "vitest",
52
+ "prepublishOnly": "pnpm check:exports"
53
+ },
54
+ "devDependencies": {
55
+ "@arethetypeswrong/cli": "^0.18.1",
56
+ "@electric-sql/pglite": "workspace:*",
57
+ "@electric-sql/pglite-utils": "workspace:*",
58
+ "@types/node": "^20.16.11",
59
+ "vitest": "^2.1.2"
60
+ },
61
+ "peerDependencies": {
62
+ "@electric-sql/pglite": "workspace:*"
63
+ }
64
+ }