Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where is the console API for WebKit/Safari?

WebKit/Safari supports the console object, which is similar to what Firebug does. But what exactly is supported? There is a console documentation for Firebug, but where can I find the console documentation for Safari/WebKit?

like image 606
avernet Avatar asked Sep 11 '08 01:09

avernet


People also ask

How do I view console output in Safari?

To do that, go into Safari's preferences (Safari Menu > Preferences) and select the Advanced Tab. Once that menu is enabled, you will find the developer console by clicking on Develop > Show Javascript Console. You can also use the shortcut Option + ⌘ + C .

Is console log part of Web API?

The console object is a Web API provided by the Browser to the JavaScript Engine, much like DOM, Fetch, History, Service Workers and Web Storage APIs.

What is browser console IPAD?

The Console. The console offers a way to inspect and debug your webpages. Think of it as the Terminal of your web content. The console has access to the DOM and JavaScript of the open page.


1 Answers

Supported methods were originally:

  • console.log()
  • console.error()
  • console.warn()
  • console.info()

Newer versions of WebKit also add the following methods making the WebKit console API almost identical to Firebug's console API:

  • console.count()
  • console.debug()
  • console.profileEnd()
  • console.trace()
  • console.dir()
  • console.dirxml()
  • console.assert()
  • console.time()
  • console.profile()
  • console.timeEnd()
  • console.group()
  • console.groupEnd()

(New information based on the WebKit nightly build WebKit-SVN-r37126, at the time of writing these methods aren't available in Safari)

like image 61
georgebrock Avatar answered Oct 18 '22 03:10

georgebrock