Skip to content

Commit

Permalink
build(deps-dev): replace standard with neostandard
Browse files Browse the repository at this point in the history
  • Loading branch information
Fdawgs committed Dec 8, 2024
1 parent d74bbc0 commit 1da0bd9
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 18 deletions.
11 changes: 3 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
"type": "commonjs",
"types": "types/index.d.ts",
"scripts": {
"lint": "standard",
"lint:fix": "standard --fix",
"lint": "eslint",
"lint:fix": "eslint --fix",
"test:unit": "c8 --100 node --test",
"test:typescript": "tsd",
"test": "npm run lint && npm run test:unit && npm run test:typescript"
Expand Down Expand Up @@ -39,12 +39,7 @@
"devDependencies": {
"@fastify/pre-commit": "^2.1.0",
"c8": "^9.1.0",
"standard": "^17.1.0",
"neostandard": "^0.11.9",
"tsd": "^0.31.0"
},
"standard": {
"ignore": [
"types/*"
]
}
}
19 changes: 9 additions & 10 deletions types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,18 @@
* @constructor
*/
declare class RefResolver {

/**
* @param {object} opts - Options for the resolver.
* @param {boolean} opts.allowEqualDuplicates - Whether to allow schemas with equal ids to be added to the resolver.
*/
constructor(opts?: { allowEqualDuplicates?: boolean });
constructor (opts?: { allowEqualDuplicates?: boolean })

/**
* Adds the given schema to the resolver.
* @param {any} schema - The schema to be added.
* @param {string} schemaId - The default schema id of the schema to be added.
*/
addSchema(schema: any, schemaId?: string): void;
addSchema (schema: any, schemaId?: string): void

/**
* Returns the schema by the given schema id and jsonPointer.
Expand All @@ -25,34 +24,34 @@ declare class RefResolver {
* @param {string} jsonPointer - The jsonPointer of the schema to be returned.
* @returns {any | null} The schema by the given schema id and jsonPointer.
*/
getSchema(schemaId: string, jsonPointer?: string): any | null;
getSchema (schemaId: string, jsonPointer?: string): any | null

/**
* Returns true if the schema by the given schema id is added to the resolver.
* @param {string} schemaId - The schema id of the schema to be checked.
* @returns {boolean} True if the schema by the given schema id is added to the resolver.
*/
hasSchema(schemaId: string): boolean;
hasSchema (schemaId: string): boolean

/**
* Returns the schema references of the schema by the given schema id.
* @param {string} schemaId - The schema id of the schema whose references are to be returned.
* @returns {Array<{ schemaId: string; jsonPointer: string }>} The schema references of the schema by the given schema id.
*/
getSchemaRefs(schemaId: string): { schemaId: string; jsonPointer: string }[];
getSchemaRefs (schemaId: string): { schemaId: string; jsonPointer: string }[]

/**
* Returns all the schema dependencies of the schema by the given schema id.
* @param {string} schemaId - The schema id of the schema whose dependencies are to be returned.
* @returns {object} The schema dependencies of the schema by the given schema id.
*/
getSchemaDependencies(schemaId: string): { [key: string]: any };
getSchemaDependencies (schemaId: string): { [key: string]: any }

/**
* Dereferences the schema by the given schema id.
* @param {string} schemaId - The schema id of the schema to be dereferenced.
*/
derefSchema(schemaId: string): void;
derefSchema (schemaId: string): void

/**
* Returns the dereferenced schema by the given schema id and jsonPointer.
Expand All @@ -62,7 +61,7 @@ declare class RefResolver {
* @param {string} jsonPointer - The jsonPointer of the schema to be returned.
* @returns {any | null} The dereferenced schema by the given schema id and jsonPointer.
*/
getDerefSchema(schemaId: string, jsonPointer?: string): any | null;
getDerefSchema (schemaId: string, jsonPointer?: string): any | null
}

export { RefResolver };
export { RefResolver }

0 comments on commit 1da0bd9

Please sign in to comment.