3

This is a real noob question, but i'm fairly new to developing C# in combination with ASP.NET and JS. I have a situation where I have javascript stored in a database and which is rendered dynamically on a page.

Because of the size of the page it is difficult to find the scripts client side and therefore it is hard to debug the javascript. I now change the scripts in the DB and add alerts to display my debugging results, is there an easier way to set some sort of breakpoint in my script?

Anil Shabitsomin

1 Answer 1

3

I'm not realy sure what you are looking for but it is possible to add a

debugger; 

statement to your Javascript code. All browsers will break on it and you are able to debug your script.

Grt, Patrick

Sign up to request clarification or add additional context in comments.

2 Comments

+1... after years and years of working with javascript in browsers, I only now just discover this!!
:) I noticed before that is this apparently one of the best hidden features of Javascript.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.