https://github.com/131/debug
debug
https://github.com/131/debug
Last synced: about 1 year ago
JSON representation
debug
- Host: GitHub
- URL: https://github.com/131/debug
- Owner: 131
- Created: 2019-03-12T14:32:30.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2024-06-06T23:25:55.000Z (about 2 years ago)
- Last Synced: 2025-02-17T09:16:43.060Z (over 1 year ago)
- Language: JavaScript
- Size: 11.7 KB
- Stars: 1
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
[debug](http://github.com/131/debug) is tiny, no dependecy alternative to [debug](http://github.com/visionmedia/debug).
[debug](http://github.com/131/debug) also allows you to customize debug output format using the `DEBUG_FORMAT`.
[](https://travis-ci.org/131/debug)
[](https://www.npmjs.com/package/debug)
[](http://opensource.org/licenses/MIT)
# DEBUG_FILE
Declare env DEBUG_FILE as the debug target
# Available format for DEBUG_FORMAT
* use :time for ISO timestamp
* use :namespace for debug namespace
* use :body for main payload
* use :diff for last msg diff
Defaut DEBUG_FORMAT is ":time :namespace :body"
# Support for console.log/console.error
debug will duplex everything to the console into the trace file
# Support for debug
debug will overrite debug.log (per specifications) to a dedicated file
# Browserify recommandation
Exclude debug from browserify is a good way to make sure only one debug reference is loaded.
# Credits
* [131](https://github.com/131) author
* [debug](https://github.com/visionmedia/debug)