Monday, June 16, 2014

How to Experiment with JavaScript Code inside your Browser?

Are you a JavaScript developer? Have you faced issues like how to readily test your JavaScript code? 

There are couple of things that can be done to solve this issue:

1. Use some online tool like Codepen
2. Use some editors

Using the first option requires to have always an internet connection and second option is slow. What if you get the facility offline right in your browser?

Scratchpad is such a tool available in Firefox browser. 

  • It provides an environment for experimenting with JavaScript code. 
  • You can write and test code ideas that interact with the contents of the web page, before switching to your usual development tools to finalize and clean up the end result.
To open the Scratchpad window, press Shift+F4, or go to the Web Developer menu (which is a submenu in the Tools menu on Mac OSX and Linux), then select Scratchpad. This will open up a Scratchpad editor window, which includes a comment that provides some brief information about how to use Scratchpad. From there you can immediately start writing some JavaScript code to try.

No comments: