has-script
    TypeScript icon, indicating that this package has built-in type declarations

    1.0.0 • Public • Published

    has-script

    npm typescript GitHub stars Twitter Follow

    Check if package.json contains a script.

    Installation

    yarn add has-script
    npm install has-script

    API

    import { hasScript, hasScriptLike } from "has-script";
     
    // Returns true if the exact match exists in the package.json script field.
    function hasScript(name: string): Promise<boolean>;
     
    // All strings that match the given RegExp.
    function hasScriptLike(regex: RegExp): Promise<string[]>;

    Dependenciesdependencies

    • @bconnorwhite/package: A utility for reading package.json of a project, and forming paths relative to it.

    Dev DependenciesDavid


    License license

    MIT

    Keywords

    none

    Install

    npm i has-script

    DownloadsWeekly Downloads

    14

    Version

    1.0.0

    License

    MIT

    Unpacked Size

    5.33 kB

    Total Files

    6

    Last publish

    Collaborators

    • bconnorwhite