@truto/sqlite-builder 2.0.1 → 2.0.2-canary.10
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 +0 -675
- package/index.js +1 -0
- package/package.json +1 -88
- package/LICENSE +0 -21
- package/dist/constants.d.ts +0 -10
- package/dist/constants.d.ts.map +0 -1
- package/dist/filter.d.ts +0 -6
- package/dist/filter.d.ts.map +0 -1
- package/dist/fragment.d.ts +0 -14
- package/dist/fragment.d.ts.map +0 -1
- package/dist/index.d.ts +0 -7
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -548
- package/dist/index.js.map +0 -13
- package/dist/sql.d.ts +0 -51
- package/dist/sql.d.ts.map +0 -1
- package/dist/types.d.ts +0 -74
- package/dist/types.d.ts.map +0 -1
package/package.json
CHANGED
|
@@ -1,88 +1 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@truto/sqlite-builder",
|
|
3
|
-
"version": "2.0.1",
|
|
4
|
-
"description": "Safe, zero-dependency template-literal tag for SQLite queries in any JS environment",
|
|
5
|
-
"keywords": [
|
|
6
|
-
"sqlite",
|
|
7
|
-
"tagged template",
|
|
8
|
-
"sql",
|
|
9
|
-
"injection-safe",
|
|
10
|
-
"javascript",
|
|
11
|
-
"typescript",
|
|
12
|
-
"template-literal",
|
|
13
|
-
"database",
|
|
14
|
-
"query-builder"
|
|
15
|
-
],
|
|
16
|
-
"homepage": "https://github.com/trutohq/truto-sqlite-builder#readme",
|
|
17
|
-
"bugs": {
|
|
18
|
-
"url": "https://github.com/trutohq/truto-sqlite-builder/issues"
|
|
19
|
-
},
|
|
20
|
-
"repository": {
|
|
21
|
-
"type": "git",
|
|
22
|
-
"url": "https://github.com/trutohq/truto-sqlite-builder.git"
|
|
23
|
-
},
|
|
24
|
-
"license": "MIT",
|
|
25
|
-
"author": "Truto <eng@truto.one>",
|
|
26
|
-
"type": "module",
|
|
27
|
-
"exports": {
|
|
28
|
-
".": {
|
|
29
|
-
"import": "./dist/index.js",
|
|
30
|
-
"types": "./dist/index.d.ts"
|
|
31
|
-
}
|
|
32
|
-
},
|
|
33
|
-
"main": "./dist/index.js",
|
|
34
|
-
"types": "./dist/index.d.ts",
|
|
35
|
-
"files": [
|
|
36
|
-
"dist/**/*",
|
|
37
|
-
"README.md",
|
|
38
|
-
"LICENSE"
|
|
39
|
-
],
|
|
40
|
-
"scripts": {
|
|
41
|
-
"build": "bun build src/index.ts --outdir dist --sourcemap=linked && tsc --emitDeclarationOnly",
|
|
42
|
-
"build:declaration": "tsc --emitDeclarationOnly",
|
|
43
|
-
"dev": "vitest --watch",
|
|
44
|
-
"format": "prettier --write .",
|
|
45
|
-
"format:check": "prettier --check .",
|
|
46
|
-
"lint": "eslint",
|
|
47
|
-
"lint:fix": "eslint --fix",
|
|
48
|
-
"prepublishOnly": "bun run typecheck && bun run lint && bun test && bun run build",
|
|
49
|
-
"test": "vitest",
|
|
50
|
-
"test:coverage": "vitest --coverage",
|
|
51
|
-
"test:ui": "vitest --ui",
|
|
52
|
-
"typecheck": "tsc --noEmit"
|
|
53
|
-
},
|
|
54
|
-
"lint-staged": {
|
|
55
|
-
"*.{ts,tsx}": [
|
|
56
|
-
"bun run eslint --fix"
|
|
57
|
-
],
|
|
58
|
-
"*.{json,md,yml,yaml}": [
|
|
59
|
-
"bun run prettier --write"
|
|
60
|
-
]
|
|
61
|
-
},
|
|
62
|
-
"devDependencies": {
|
|
63
|
-
"@changesets/cli": "2.29.5",
|
|
64
|
-
"@eslint/js": "9.29.0",
|
|
65
|
-
"@types/bun": "latest",
|
|
66
|
-
"@typescript-eslint/eslint-plugin": "8.34.1",
|
|
67
|
-
"@typescript-eslint/parser": "8.34.1",
|
|
68
|
-
"@vitest/coverage-v8": "3.2.4",
|
|
69
|
-
"@vitest/ui": "3.2.4",
|
|
70
|
-
"eslint": "9.29.0",
|
|
71
|
-
"eslint-config-prettier": "10.1.5",
|
|
72
|
-
"eslint-plugin-prettier": "5.5.0",
|
|
73
|
-
"eslint-plugin-security": "3.0.1",
|
|
74
|
-
"globals": "16.2.0",
|
|
75
|
-
"husky": "9.1.7",
|
|
76
|
-
"lint-staged": "16.1.2",
|
|
77
|
-
"prettier": "3.5.3",
|
|
78
|
-
"prettier-plugin-packagejson": "2.5.15",
|
|
79
|
-
"typescript": "5.8.3",
|
|
80
|
-
"vitest": "3.2.4"
|
|
81
|
-
},
|
|
82
|
-
"engines": {
|
|
83
|
-
"bun": ">=1.0.0"
|
|
84
|
-
},
|
|
85
|
-
"publishConfig": {
|
|
86
|
-
"access": "public"
|
|
87
|
-
}
|
|
88
|
-
}
|
|
1
|
+
{"name":"@truto/sqlite-builder","version":"2.0.2-canary.10","description":"debug canary","license":"MIT","main":"index.js"}
|
package/LICENSE
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2024 Truto Team
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
package/dist/constants.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Common regex patterns and limits used across the codebase
|
|
3
|
-
*/
|
|
4
|
-
export declare const MAX_QUERY_LENGTH = 102400;
|
|
5
|
-
export declare const MAX_IDENTIFIER_LENGTH = 255;
|
|
6
|
-
export declare const MAX_PATTERN_LENGTH = 1024;
|
|
7
|
-
export declare const STACKED_QUERY_REGEX: RegExp;
|
|
8
|
-
export declare const QUALIFIED_IDENTIFIER_REGEX: RegExp;
|
|
9
|
-
export declare const SIMPLE_IDENTIFIER_REGEX: RegExp;
|
|
10
|
-
//# sourceMappingURL=constants.d.ts.map
|
package/dist/constants.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../src/constants.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,eAAO,MAAM,gBAAgB,SAAS,CAAA;AAKtC,eAAO,MAAM,qBAAqB,MAAM,CAAA;AAMxC,eAAO,MAAM,kBAAkB,OAAO,CAAA;AAMtC,eAAO,MAAM,mBAAmB,QAAe,CAAA;AAG/C,eAAO,MAAM,0BAA0B,QACgB,CAAA;AAGvD,eAAO,MAAM,uBAAuB,QAA6B,CAAA"}
|
package/dist/filter.d.ts
DELETED
package/dist/filter.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"filter.d.ts","sourceRoot":"","sources":["../src/filter.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAGV,YAAY,EACZ,UAAU,EACX,MAAM,SAAS,CAAA;AAgZhB;;GAEG;AACH,wBAAgB,aAAa,CAAC,MAAM,EAAE,UAAU,GAAG,YAAY,CAuB9D"}
|
package/dist/fragment.d.ts
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import type { SqlFragment } from './types';
|
|
2
|
-
/**
|
|
3
|
-
* Create and register an immutable, branded SQL fragment.
|
|
4
|
-
*
|
|
5
|
-
* The returned object is frozen (including its values array) so callers cannot
|
|
6
|
-
* mutate a fragment after the integrity checks that produced it.
|
|
7
|
-
*/
|
|
8
|
-
export declare function createFragment(text: string, values: readonly unknown[]): SqlFragment;
|
|
9
|
-
/**
|
|
10
|
-
* Type guard: was this value minted by the library (and therefore trusted to
|
|
11
|
-
* contribute raw SQL text)?
|
|
12
|
-
*/
|
|
13
|
-
export declare function isSqlFragment(value: unknown): value is SqlFragment;
|
|
14
|
-
//# sourceMappingURL=fragment.d.ts.map
|
package/dist/fragment.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fragment.d.ts","sourceRoot":"","sources":["../src/fragment.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,SAAS,CAAA;AAkB1C;;;;;GAKG;AACH,wBAAgB,cAAc,CAC5B,IAAI,EAAE,MAAM,EACZ,MAAM,EAAE,SAAS,OAAO,EAAE,GACzB,WAAW,CASb;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,WAAW,CAMlE"}
|
package/dist/index.d.ts
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* truto-sqlite-builder - Safe, zero-dependency template-literal tag for SQLite queries
|
|
3
|
-
*/
|
|
4
|
-
export { compileFilter } from './filter';
|
|
5
|
-
export { sql } from './sql';
|
|
6
|
-
export type { FilterResult, JsonFilter, SqlQuery } from './types';
|
|
7
|
-
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAA;AACxC,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAA;AAC3B,YAAY,EAAE,YAAY,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAA"}
|