Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

ServiceNow Exam CAD Topic 1 Question 92 Discussion

Actual exam question for ServiceNow's CAD exam
Question #: 92
Topic #: 1
[All CAD Questions]

Which options are strategies for debugging client-side scripts?

Choose 2 answers

Show Suggested Answer Hide Answer
Suggested Answer: B, C

Comprehensive and Detailed In-Depth

Debugging client-side scripts in ServiceNow involves utilizing tools and methods that operate within the user's browser environment, as client-side scripts execute there.

A . gs.addErrorMessage(): This function is used in server-side scripts to add error messages to the session and is not applicable for client-side debugging.

B . g_form.addInfoMessage(): This client-side function displays informational messages to the user on the form. While primarily used for user communication, it can aid in debugging by confirming the execution of certain script sections.

C . jslog(): This function logs messages to the JavaScript log, which can be viewed using browser developer tools. It's a valuable tool for debugging client-side scripts by providing runtime information.

servicenow.com

D . gs.log(): This function logs messages on the server side and is not available in client-side scripting.

Additionally, developers can use the debugger; statement within their client-side scripts. When the browser's developer tools are open, encountering this statement will pause script execution, allowing for step-by-step inspection.


Contribute your Thoughts:

Tora
5 days ago
I think options C and D are strategies for debugging client-side scripts.
upvoted 0 times
...

Save Cancel
a