Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@travetto/model

Package Overview
Dependencies
Maintainers
1
Versions
371
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@travetto/model - npm Package Compare versions

Comparing version 0.0.8 to 0.0.9

2

package.json

@@ -23,3 +23,3 @@ {

},
"version": "0.0.8"
"version": "0.0.9"
}
export type SortOptions = { [key: string]: number } | string | string[];
export type FieldComparableType = Date | number;
export type FieldType = string | number | boolean | Date | object;
export type FieldType = FieldComparableType | string | boolean;
export type FieldArrayType = FieldType[];
export function isSubQuery(o: any): o is SubQuery {
return o.$lt || o.$lte || o.$gt || o.$gte || o.$eq || o.$ne || o.$in || o.$nin || o.$exists;
}
export type Point = [number, number];
export type SubQuery = {
$lt: FieldComparableType;
$lte?: FieldComparableType;
$gt?: FieldComparableType;
$gte?: FieldComparableType;
$eq?: FieldType;
$ne?: FieldType;
$in?: FieldArrayType;
$nin?: FieldArrayType;
$exists?: boolean;
}
export type FieldQuery =
{ lt: FieldComparableType; } |
{ lte: FieldComparableType; } |
{ gt: FieldComparableType; } |
{ gte: FieldComparableType; } |
{ eq: FieldType; } |
{ ne: FieldType; } |
{ in: FieldArrayType; } |
{ nin: FieldArrayType; } |
{ all: FieldArrayType; } |
{ exists: boolean; } |
{ regex: RegExp; } |
{ geoWithin: Point[] } |
{ geoIntersects: Point[] } |
FieldType;
export type Query = {
[key: string]: FieldType | RegExp | SubQuery;
} & {
$and?: Query[],
$or?: Query[]
};
export type Query =
{ and: Query[]; } |
{ or: Query[]; } |
{ not: Query; } |
{ [key: string]: FieldQuery; };
export interface QueryOptions {

@@ -37,2 +37,4 @@ sort?: SortOptions;

export type ModelId = string | number;
let q: Query = {
'name.first': 'orange'
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc