Dev env and debugging

Dev env and debugging
0

#1

Hi

I started going over the Baic Algorithms Scirpts section and when working in FCC in browser editor I am trying to use console.log to debug my code, but it doesnt seem to print anything. what am i missing here? this also maked me wonder how other folks around the campfire work - are you using FCC editor or something extrernal, and what are my debug possibilities when working on html/js ( i know perl/c etc but not familiar with the web dev tools at all).

Thanks.


#2

Press Ctrl + Shift + J to open browser console. There you’ll see all your console.log() statements.


#3

Thanks. indeed i know see these prints.
another question - how can i execute just the code in the editor (that is the in browser editor). more specifically i want to debug a certain testcase - not run all of them - is this possible?


#4

Hello,

Hit f12 or right click, inspect element.

Then choose console tab.

That what you meant?

Cheers

Mark


#5

You could use something like https://repl.it/languages/javascript or http://jsbin.com


#6

Hmmm somehow I didn’t see the other posts! Sorry to duplicate.


#7

Thanks @jenovs @MARKJ78.
so that helped me get through the task i’ve been trying to debug.
now i know about the browser console and that there’s a website to coee and run JS (btw i dont see console reactions there), i have to wonder - is there a sublime text plugin to rule them all?


#8

No (as far as I’m aware) , but there are whole js testing suits and libraries that integrate into your code. Can’t tell you anymore than that because I haven’t learned them yet!

You can prob get a linting (syntax) plugin though.