tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

no-cu-reportError.rst (525B)


      1 no-cu-reportError
      2 =================
      3 
      4 Disallows Cu.reportError. This has been deprecated and should be replaced by
      5 console.error.
      6 
      7 Examples of incorrect code for this rule:
      8 -----------------------------------------
      9 
     10 .. code-block:: js
     11 
     12    Cu.reportError("message");
     13    Cu.reportError("message", stack);
     14 
     15 Examples of correct code for this rule:
     16 ---------------------------------------
     17 
     18 .. code-block:: js
     19 
     20    console.error("message");
     21    let error = new Error("message");
     22    error.stack = stack;
     23    console.error(error);