1.7.0 • Published 4 years ago

superlogs-loader v1.7.0

Weekly downloads
-
License
MIT
Repository
github
Last release
4 years ago

🦄 superlogs-loader

All Contributors

SuperLogs webpack loader for webpack

Superlogs is a super logical logging solution.

This package will find and replace doccomments with superlogs at build time.

Install:

$ npm install --save-dev superlogs-loader

or using yarn

$ yarn add superlogs-loader --dev

Configuration:

In your webpack.config.js:

module.exports = {
  // ...
  module: {
    rules: [
      {
        test: /\.ts?$/,
        loader: 'superlogs-loader',
        options: {
          
        }
      }
    ]
  }
}

or for razzle

module.exports = {
  // ...
  modify: (config, { target, dev }, webpack) => {
    config.module.rules.push(
      {
        test: /\.ts?$/,
        loader: 'superlogs-loader',
        options: {
          
        }
      }
    );
  }
}  

Usage

method

In your target file

/**
 * @method method description
 */

This will be replaced after build with superlogs

logs.addMethod('method description');

step

In your target file

/**
 * @step step description
 */

This will be replaced after build with superlogs

logs.addStep('step description');

data

In your target file

/**
 * @data debugVar
 */

This will be replaced after build with superlogs

logs.addData('debugVar', debugVar);

mongo

In your target file

/**
 * @mongo mongo description
 */

This will be replaced after build with superlogs

logs.addMongo('mongo description');

dispatch

In your target file

/**
 * @dispatch dispatch type
 * @payload setPayload(true)
 */

This will be replaced after build with superlogs

logs.addDispatch('dispatch description', setPayload(true));

Contributing:

Feel free to open issues to propose stuff and participate.

Pull requests are also welcome.

Licence:

MIT

Contributors ✨

Thanks goes to these wonderful people (emoji key):

This project follows the all-contributors specification. Contributions of any kind welcome!

1.7.0

4 years ago

1.6.0

4 years ago

1.5.34

4 years ago

1.5.33

4 years ago

1.5.32

4 years ago

1.5.31

4 years ago

1.5.30

4 years ago

1.5.29

4 years ago

1.5.28

4 years ago

1.5.27

4 years ago

1.5.26

4 years ago

1.5.25

4 years ago

1.5.24

4 years ago

1.5.23

4 years ago

1.5.22

4 years ago

1.5.21

4 years ago

1.5.20

4 years ago

1.5.19

4 years ago

1.5.18

4 years ago

1.5.17

4 years ago

1.5.16

4 years ago

1.5.15

4 years ago

1.5.14

4 years ago

1.5.13

4 years ago

1.5.12

4 years ago

1.5.11

4 years ago

1.5.10

4 years ago

1.5.9

4 years ago

1.5.8

4 years ago

1.5.7

4 years ago

1.5.6

4 years ago

1.5.5

4 years ago

1.5.4

4 years ago

1.5.3

4 years ago

1.5.2

4 years ago

1.5.1

4 years ago

1.5.0

4 years ago

1.2.0

4 years ago

1.1.9

4 years ago

1.1.8

4 years ago

1.1.7

4 years ago

1.1.6

4 years ago

1.1.5

4 years ago

1.1.4

4 years ago

1.1.3

4 years ago

1.1.2

4 years ago

1.1.1

4 years ago

1.1.0

4 years ago