@rljson/rljson 0.0.38 → 0.0.39
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/dist/content/table-cfg.d.ts +11 -0
- package/dist/rljson.js +15 -0
- package/package.json +8 -8
|
@@ -68,6 +68,17 @@ export interface TableCfg extends Json {
|
|
|
68
68
|
* A table containing columns
|
|
69
69
|
*/
|
|
70
70
|
export type TablesCfgTable = RljsonTable<TableCfg, 'ingredients'>;
|
|
71
|
+
/**
|
|
72
|
+
* Offers tools for working with table configurations
|
|
73
|
+
*/
|
|
74
|
+
export declare class TableCfgTools {
|
|
75
|
+
readonly tableCfg: TableCfg;
|
|
76
|
+
constructor(tableCfg: TableCfg);
|
|
77
|
+
/**
|
|
78
|
+
* Returns all column keys
|
|
79
|
+
*/
|
|
80
|
+
get columnKeys(): ColumnKey[];
|
|
81
|
+
}
|
|
71
82
|
/**
|
|
72
83
|
* Example matching allTypesRow
|
|
73
84
|
*/
|
package/dist/rljson.js
CHANGED
|
@@ -524,6 +524,20 @@ __publicField(_Example, "broken", {
|
|
|
524
524
|
});
|
|
525
525
|
let Example = _Example;
|
|
526
526
|
// @license
|
|
527
|
+
class TableCfgTools {
|
|
528
|
+
constructor(tableCfg) {
|
|
529
|
+
this.tableCfg = tableCfg;
|
|
530
|
+
}
|
|
531
|
+
/**
|
|
532
|
+
* Returns all column keys
|
|
533
|
+
*/
|
|
534
|
+
get columnKeys() {
|
|
535
|
+
const columnNames = Object.keys(this.tableCfg.columns).filter(
|
|
536
|
+
(e) => !e.startsWith("_")
|
|
537
|
+
);
|
|
538
|
+
return columnNames;
|
|
539
|
+
}
|
|
540
|
+
}
|
|
527
541
|
const exampleTableCfgTable = () => Example.ok.singleRow().tableCfgs;
|
|
528
542
|
const exampleTableCfg = (tableCfg = void 0) => {
|
|
529
543
|
return {
|
|
@@ -1490,6 +1504,7 @@ class Validate {
|
|
|
1490
1504
|
export {
|
|
1491
1505
|
BaseValidator,
|
|
1492
1506
|
Example,
|
|
1507
|
+
TableCfgTools,
|
|
1493
1508
|
Validate,
|
|
1494
1509
|
bakeryExample,
|
|
1495
1510
|
contentTypes,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rljson/rljson",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.39",
|
|
4
4
|
"packageManager": "pnpm@10.6.3",
|
|
5
5
|
"description": "The RLJSON data format specification",
|
|
6
6
|
"homepage": "https://github.com/rljson/rljson",
|
|
@@ -29,20 +29,20 @@
|
|
|
29
29
|
"updateGoldens": "cross-env UPDATE_GOLDENS=true npm test"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"@types/node": "^22.
|
|
33
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
34
|
-
"@typescript-eslint/parser": "^8.
|
|
32
|
+
"@types/node": "^22.14.1",
|
|
33
|
+
"@typescript-eslint/eslint-plugin": "^8.30.1",
|
|
34
|
+
"@typescript-eslint/parser": "^8.30.1",
|
|
35
35
|
"@vitest/coverage-v8": "^3.1.1",
|
|
36
36
|
"cross-env": "^7.0.3",
|
|
37
|
-
"eslint": "^9.
|
|
37
|
+
"eslint": "^9.25.0",
|
|
38
38
|
"eslint-plugin-jsdoc": "^50.6.9",
|
|
39
39
|
"eslint-plugin-tsdoc": "^0.4.0",
|
|
40
40
|
"globals": "^16.0.0",
|
|
41
41
|
"jsdoc": "^4.0.4",
|
|
42
42
|
"read-pkg": "^9.0.1",
|
|
43
|
-
"typescript": "~5.8.
|
|
44
|
-
"typescript-eslint": "^8.
|
|
45
|
-
"vite": "^6.2
|
|
43
|
+
"typescript": "~5.8.3",
|
|
44
|
+
"typescript-eslint": "^8.30.1",
|
|
45
|
+
"vite": "^6.3.2",
|
|
46
46
|
"vite-node": "^3.1.1",
|
|
47
47
|
"vite-plugin-dts": "^4.5.3",
|
|
48
48
|
"vite-tsconfig-paths": "^5.1.4",
|