Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

webpack-isomorphic-compiler-reporter

Package Overview
Dependencies
Maintainers
18
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

webpack-isomorphic-compiler-reporter

Pretty reporting for webpack-isomorphic-compiler

  • 1.3.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
175
increased by52.17%
Maintainers
18
Weekly downloads
 
Created
Source

webpack-isomorphic-compiler-reporter

NPM version Downloads Build Status Coverage Status Dependency status Dev Dependency status Greenkeeper badge

Beautiful reporting for webpack-isomorphic-compiler compilation events.

While webpack-sane-compiler-reporter works fine with this compiler, the output is incomplete. This reporter is specially designed to be isomorphic aware.

Example output

Installation

$ npm install webpack-isomorphic-compiler-reporter --save-dev

Usage

const startReporting = require('webpack-isomorphic-compiler-reporter');

const { stop, options } = startReporting(compiler, {/* options */});

// Now, just call compiler.run() or compiler.watch() to start a compilation and start outputting reports
// Calling stop() will stop listening to the compiler events
// Furthermore, you have access to the options that were computed by the merge of provided options and the defaults

Available options

NameDescriptionTypeDefault
statsDisplay webpack stats after each compilationboolean/string (true, false or 'once')true
humanErrorsDetects human errors related to webpack configuration mistakes (done only once)booleantrue
writeFunction responsible for printing/outputting the generated report messagesfunctionPrints to stderr
printStartFunction responsible for generating a message for when a compilation startsfunctionExample output
printSuccessFunction responsible for generating a message when a compilation succeedsfunctionExample output
printFailureFunction responsible for generating a message when a compilation failsfunctionExample output
printInvalidateFunction responsible for generating a message when invalidate() is called when watchingfunctionExample output
printStatsFunction responsible for generating a message representing a WebpackStats instancefunctionExample client  output Example server output
printErrorFunction responsible for generating a message of a Error instancefunctionExample output

Other exports

renderers

For convenience this package also exports the renderers used internally:

const reporter = require('webpack-isomorphic-compiler-reporter');

reporter(compiler, {
    printError: (err) => `${reporter.renderers.renderError(err)}\n`,
});
symbols

You can also access the symbols that precede some messages.

const reporter = require('webpack-isomorphic-compiler-reporter');

reporter(compiler, {
    printStart: () => `${reporter.symbols.start} A iniciar a compilação...\n`,
});

Tests

$ npm test
$ npm test -- --watch during development

License

MIT License

Keywords

FAQs

Package last updated on 05 Mar 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc