npm.io
1.4.3 • Published 2 years ago

@types/gulp-newer

Licence
MIT
Version
1.4.3
Deps
1
Size
6 kB
Vulns
0
Weekly
0
Stars
51.4K

Installation

npm install --save @types/gulp-newer

Summary

This package contains type definitions for gulp-newer (https://github.com/tschaub/gulp-newer).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/gulp-newer.

index.d.ts

/// <reference types="node"/>

interface IDestinationOption {
    /**
     * Path to destination directory or file.
     */
    dest: string;
}

interface IExtOption {
    /**
     * Source files will be matched to destination files with the provided extension.
     */
    ext: string;
}

interface IMapOption {
    /**
     * Map relative source paths to relative destination paths.
     */
    map: (relativePath: string) => string;
}

interface IExtraOption {
    /**
     * An extra file, file glob, or list of extra files and/or globs, to check for updated time stamp(s).
     * If any of these files are newer than the destination files, then all source files will be passed into the stream.
     */
    extra?: string | string[];
}

type ValidOptionPermutations =
    | (IDestinationOption & Partial<IExtOption> & Partial<IMapOption>)
    | (Partial<IDestinationOption> & Partial<IExtOption> & IMapOption);

type IOptions = IExtraOption & ValidOptionPermutations;

interface IGulpNewer {
    /**
     * Create a transform stream that passes through files whose modification time
     * is more recent than the corresponding destination file's modification time.
     * @param dest Path to destination directory or file.
     */
    (dest: string): NodeJS.ReadWriteStream;

    /**
     * Create a transform stream that passes through files whose modification time
     * is more recent than the corresponding destination file's modification time.
     */
    (options: IOptions): NodeJS.ReadWriteStream;
}

declare const newer: IGulpNewer;
export = newer;

Additional Details

  • Last updated: Tue, 07 Nov 2023 0337 GMT
  • Dependencies: @types/node

Credits

These definitions were written by Thomas Corbière.