@types/folder-hash
Advanced tools
Comparing version 4.0.0 to 4.0.1
@@ -10,15 +10,15 @@ // Type definitions for folder-hash 4.0 | ||
export interface FolderAndFileOptions { | ||
exclude?: string[] | PathGlobFunction; | ||
include?: string[] | PathGlobFunction; | ||
matchBasename?: boolean; | ||
matchPath?: boolean; | ||
ignoreBasename?: boolean; | ||
ignoreRootName?: boolean; | ||
exclude?: string[] | PathGlobFunction | undefined; | ||
include?: string[] | PathGlobFunction | undefined; | ||
matchBasename?: boolean | undefined; | ||
matchPath?: boolean | undefined; | ||
ignoreBasename?: boolean | undefined; | ||
ignoreRootName?: boolean | undefined; | ||
} | ||
export type SymbolicLinkOptions = Omit<FolderAndFileOptions, "exclude" | "include"> & { | ||
include?: boolean; | ||
ignoreTargetPath?: boolean; | ||
ignoreTargetContent?: boolean; | ||
ignoreTargetContentAfterError?: boolean; | ||
include?: boolean | undefined; | ||
ignoreTargetPath?: boolean | undefined; | ||
ignoreTargetContent?: boolean | undefined; | ||
ignoreTargetContentAfterError?: boolean | undefined; | ||
}; | ||
@@ -28,8 +28,8 @@ export interface HashElementOptions { | ||
// Defaults to 'sha1'. | ||
algo?: string; | ||
algo?: string | undefined; | ||
// Defaults to 'base64' | ||
encoding?: "base64" | "hex" | "binary"; | ||
files?: FolderAndFileOptions; | ||
folders?: FolderAndFileOptions; | ||
symbolicLinks?: SymbolicLinkOptions; | ||
encoding?: "base64" | "hex" | "binary" | undefined; | ||
files?: FolderAndFileOptions | undefined; | ||
folders?: FolderAndFileOptions | undefined; | ||
symbolicLinks?: SymbolicLinkOptions | undefined; | ||
} | ||
@@ -36,0 +36,0 @@ |
{ | ||
"name": "@types/folder-hash", | ||
"version": "4.0.0", | ||
"version": "4.0.1", | ||
"description": "TypeScript definitions for folder-hash", | ||
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/folder-hash", | ||
"license": "MIT", | ||
@@ -27,4 +28,4 @@ "contributors": [ | ||
"dependencies": {}, | ||
"typesPublisherContentHash": "c40df3e70a9a94a7bb98c16114c46430d95276146f4ff5ac4abcd8138ac3e48d", | ||
"typeScriptVersion": "3.5" | ||
"typesPublisherContentHash": "c4fa496bb425def5d81b98e4b35e463898696e9e07b2b1dc528f03bcd055f6fd", | ||
"typeScriptVersion": "3.6" | ||
} |
@@ -9,5 +9,74 @@ # Installation | ||
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/folder-hash. | ||
## [index.d.ts](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/folder-hash/index.d.ts) | ||
````ts | ||
// Type definitions for folder-hash 4.0 | ||
// Project: https://github.com/marc136/node-folder-hash#readme | ||
// Definitions by: Kevin Brown <https://github.com/thekevinbrown> | ||
// Piotr Błażejewicz <https://github.com/peterblazejewicz> | ||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped | ||
export type PathGlobFunction = () => string[]; | ||
export interface FolderAndFileOptions { | ||
exclude?: string[] | PathGlobFunction | undefined; | ||
include?: string[] | PathGlobFunction | undefined; | ||
matchBasename?: boolean | undefined; | ||
matchPath?: boolean | undefined; | ||
ignoreBasename?: boolean | undefined; | ||
ignoreRootName?: boolean | undefined; | ||
} | ||
export type SymbolicLinkOptions = Omit<FolderAndFileOptions, "exclude" | "include"> & { | ||
include?: boolean | undefined; | ||
ignoreTargetPath?: boolean | undefined; | ||
ignoreTargetContent?: boolean | undefined; | ||
ignoreTargetContentAfterError?: boolean | undefined; | ||
}; | ||
export interface HashElementOptions { | ||
// See crypto.getHashes() for options. | ||
// Defaults to 'sha1'. | ||
algo?: string | undefined; | ||
// Defaults to 'base64' | ||
encoding?: "base64" | "hex" | "binary" | undefined; | ||
files?: FolderAndFileOptions | undefined; | ||
folders?: FolderAndFileOptions | undefined; | ||
symbolicLinks?: SymbolicLinkOptions | undefined; | ||
} | ||
export interface HashElementNode { | ||
name: string; | ||
hash: string; | ||
children: HashElementNode[]; | ||
} | ||
/** | ||
* @param name element name or an element's path | ||
* @param options Options object | ||
*/ | ||
export function hashElement(name: string, options?: HashElementOptions): Promise<HashElementNode>; | ||
/** | ||
* @param name element name or an element's path | ||
* @param dir directory that contains the element (generated from name if omitted) | ||
* @param options Options object | ||
*/ | ||
export function hashElement(name: string, dir?: string, options?: HashElementOptions): Promise<HashElementNode>; | ||
/** | ||
* @param name element name or an element's path | ||
* @param dir directory that contains the element (generated from name if omitted) | ||
* @param options Options object | ||
* @param callback Error-first callback function | ||
*/ | ||
export function hashElement( | ||
name: string, | ||
dir?: string, | ||
options?: HashElementOptions, | ||
callback?: (error?: Error, result?: HashElementNode) => any, | ||
): void; | ||
export const defaults: HashElementOptions; | ||
```` | ||
### Additional Details | ||
* Last updated: Thu, 25 Mar 2021 02:21:06 GMT | ||
* Last updated: Thu, 08 Jul 2021 12:01:46 GMT | ||
* Dependencies: none | ||
@@ -14,0 +83,0 @@ * Global values: none |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No website
QualityPackage does not have a website.
Found 1 instance in 1 package
7524
0
86