JSNLog
  • Home
  • Installation
  • Getting Started
  • Documentation
  • Source
  • Support
.Net Core + JS.Net Framework + JSNode + JSJS Only
Tweet
cdnjs
Documentation Menu
How To ▶ Loading jsnlog.js ▶ CommonJS

CommonJS

jsnlog.js is available from NPM and has the necessary code to function as an CommonJS module:

  1. Install jsnlog.js from NPM:
    npm install jsnlog
  2. Load jsnlog into your code:
    var JL = require('jsnlog').JL;

CommonJS is normally used on the server, because it doesn't support asynchronous loading by the client over the network. However, Browserify enables you to use this on the client.

Documentation Menu

  1. Installation
  2. Getting Started
  3. How To
    1. Adding request headers
    2. AJAX error handling
    3. Angular 2+ logging to the server
    4. AngularJs Error Handling
    5. Content Security Policy (CSP)
    6. Setting the url to send logs to
    7. Lost connection handling
    8. JavaScript Error Handling
    9. Javascript Try Catch
    10. Log Message Batching
    11. Log Message Format
    12. Numeric Severities
    13. Obfuscated Script Errors
  4. jsnlogjs.js
    1. AjaxAppender Object
      1. sendBatch Method
      2. setOptions Method
    2. __jsnlog_configure function
    3. ConsoleAppender Object
      1. sendBatch Method
      2. setOptions Method
    4. Exception Object
    5. JL Namespace and Method
      1. createAjaxAppender Method
      2. createConsoleAppender Method
      3. getAllLevel Method
      4. getDebugLevel Method
      5. getErrorLevel Method
      6. getFatalLevel Method
      7. getInfoLevel Method
      8. getOffLevel Method
      9. getTraceLevel Method
      10. getWarnLevel Method
      11. JL Method
      12. setOptions Method
    6. Logger Object
      1. debug Method
      2. error Method
      3. fatal Method
      4. fatalException Method
      5. info Method
      6. log Method
      7. setOptions Method
      8. trace Method
      9. warn Method
© 2012-2025 Mattijs Perdeck | License: MIT