Calling a Javascript Function from Console

L3v3L picture L3v3L · Jan 29, 2012 · Viewed 158.7k times · Source

In Chrome's JavaScript console, how do I call a function that belongs to a .js file included in the webpage I am viewing?

Answer

Kevin Ennis picture Kevin Ennis · Jan 29, 2012

If it's inside a closure, i'm pretty sure you can't.

Otherwise you just do functionName(); and hit return.