How to use the hook-std function in hook-std

To help you get started, we’ve selected a few hook-std examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github webiny / webiny-js / packages-utils / webiny-semantic-release / src / index.js View on Github external
export default async config => {
    const { params, plugins } = await buildParams(config);

    // Connect to the stdout and process each line of the output using `stdOut` function
    const unhook = hookStd({ silent: false }, stdOut);
    try {
        await compose([verifyEnvironment(), ...plugins])(params);
        unhook();
        return params;
    } catch (err) {
        unhook();
        throw err;
    }
};

hook-std

Hook and modify stdout and stderr

MIT
Latest version published 3 years ago

Package Health Score

70 / 100
Full package analysis

Popular hook-std functions