TLDR; A lot of good resources for learning JavaScript exist. And you do not need to install an IDE, you can learn JavaScript in the console.
How does learning JavaScript help?
- When testing a web app you can look at the code
- Understand the code
- Understand errors written to the Dev Tools Console
- Workaround application defects
- Automate in the browser
- I can nudge the client side into different states by executing ad-hoc JavaScript through the console
- The DOM web developer displays make ever more sense
- Create helper tools as BookMarklets
- Improve your use of WebDriver’s
JavascriptExecutor
- In strange and mysterious ways that will surprise you once you learn JavaScript.
Learning JavaScript increases the Surface Area of the System that we can pull information from (i.e. model it), and potentially observe, interrogate and manipulate in more dimensions.
It increases our options, and therefore our ability to handle an increased variety of applications and technologies.
It also helps my automation;
- My ability to use the JavaScript calls has improved so I don’t have as much trouble with web sites that don’t play nice
- My CSS selector skills have improved
Clearly for most Selenium automation purposes, we don’t need a large grasp of JavaScript, we mainly do quick DOM access scripts, the kind of thing you would do through the console for debugging.
Any Resources? If you are a tester and want to learn JavaScript…
Tip 1… Automating in the Browser
My Test Automation U Course
https://testautomationu.applitools.com/automating-in-the-browser-using-javascript/
- a free course
- explains how to use the browser dev tools for automating
Tip 2… Eloquent JavaScript
Read (free) Eloquent JavaScript
Good for understanding the language. And Code Sandbox good for seeing code running.
Pull the language together to help you understand it as a programmer.
Tip 3… JavaScript Enlightenment
Read (free) JavaScript Enlightenment
An indepth look at ‘modern’ JavaScript features.
Tip 4… Speaking JavaScript
Read (free) Speaking JavaScript
A good overview of the syntax and language.
Tip 5… DOM Elightenment
Read (free) DOM Elightenment
Understand and manipulate the DOM in depth. We will do this a lot when automating from the browser.
Tip 6… JavaScript Design Patterns
Read (free) JavaScript Design Patterns
Much of the use of JavaScript will be tactical unless being used as the main language for coding automating or writing apps. This is important to learn when you start writing more code, especially if you have to maintain it. And can be useful for helping understand structure of other peoples code.
Tip 7… Support Page
The support page for my Test Automation U Course (has even more links):
Tip 8… Go Make Things
Subscribe to Chris Ferdinandi’s “Go Make Things” JavaScript newsletter.
Short, regular posts with easy to read and understand JavaScript code snippets.
Tip 9… Useful Snippets
Check out the Chrome Extension “Useful Snippets”
Viv Richards @11vlr and I wrote this web testing tool.
And the benefit is, each time you run a command you see the JS in the console.
Tip 10… JavaScript for Cats
Have a look at “JavaScript for Cats”. A tutorial web page, where all the examples and coding take place in the dev tools. And it has some additional resources for future reading.
A fast overview you can use in the browser.
Tip 11… Javascript Weekly
Subscribe to the JavaScriptWeekly.com email newsletter.
Or subscribe to their RSS feed, or read the backlog of newsletters.
This provides a good summary of posts around the web related to JavaScript.
Tip 12 - Java5cript.com
Java5cript.com is an updated list of videos, books and courses to work through. It did not exist when I first created this list, but since it does now, I thoroughly recommend reading through it.
It might be a little overwhelming at first, so I’ve put it lower on the list to try and restrict your options until you get the basics under your belt, then you will be able to explore Java5cript.com and find the next resource to help you on your journey.
Tip 13 - Impatient JS Books
Over on exploringjs.com Axel Rauschmayer has three free books covering JavaScript:
- JavaScript for Impatient Programmers
- Deep JavaScript: Theory and Techniques
- Tackling TypeScript: Upgrading from JavaScript
Tip 14… Order to use them
- Subscribe to “Go Make Things” and be drip fed information - gomakethings.com
- Subscripe to “JavaScriptWeekly.com” and receive a weekly prompt to continue to learn.
- Read JavaScript for Cats jsforcats.com
- Follow My Test Automation U Course Automating in the browser
- Read Speaking JavaScript speakingjs.com
- Eloquent JavaScript eloquentjavascript.net
- Read DOM Elightenment domenlightenment.com
- JavaScript Design Patterns addyosmani.com/resources/essentialjsdesignpatterns/book/
- Course Support Page - eviltester.com/page/onlinetraining/testautomationujs
- Useful Snippets - github.com/eviltester/usefuljssnippetextension
- Read JavaScript Enlightenment frontendmasters.com/books/javascript-enlightenment
- Read JavaScript for Impatient Programmers
- Visit Java5cript.com