Compare commits

...

No commits in common. "master" and "ts-conversion" have entirely different histories.

2 changed files with 4 additions and 8 deletions

View File

@ -1,9 +1,8 @@
{ {
"name": "lovelacejs", "name": "lovelacejs",
"version": "1.0.0", "version": "0.2.2",
"description": "Lovelace.js is a library to easily mutate data through relationships, filtering, and tranforming the shape of data.", "description": "Lovelace.js is a modern JavaScript Library to create objects that easily mutate data through relationships, filtering, and tranforming the shape of data.",
"main": "lib/index.js", "main": "index.js",
"types": "lib/index.d.ts",
"directories": { "directories": {
"test": "tests" "test": "tests"
}, },

View File

@ -1,4 +1,3 @@
import filterTypes from "../constants/filterTypes"
import Table from "../entities/Table" import Table from "../entities/Table"
import { tableRow } from "./tableTypes" import { tableRow } from "./tableTypes"
@ -9,9 +8,7 @@ type noduleConstructorProps = {
tables?: Table[] tables?: Table[]
} }
type filterKeys = keyof typeof filterTypes type filterType = 'EQUAL' | 'GREATER' | 'GREATEREQUAL' | 'LESSER' | 'LESSEREQUAL'
type filterValues = typeof filterTypes[filterKeys]
type filterType = filterValues
type filterParams = Record<string, string | number> type filterParams = Record<string, string | number>
type filterNoduleConstructionProps = noduleConstructorProps & {filterType: filterType} & {filterParams: filterParams} type filterNoduleConstructionProps = noduleConstructorProps & {filterType: filterType} & {filterParams: filterParams}