can you tell me what is the use of these isolate script tick?

Aniket Gaurikar
Tera Contributor
 
5 REPLIES 5

Dr Atul G- LNG
Tera Patron
Tera Patron

Hi @Aniket Gaurikar 

 

What is the purpose of Isolate script checkbox in client script? It manages whether DOM manipulation should be enabled/disabled for client script. If DOM manipulation code is not working then there is possibility that this checkbox is true which is forcing client script to run in strict mode.

 

 

Isolate script" field in client script which is new Feature London version

New client-scripts are run in strict mode, with direct DOM access disabled.

Access to jQuery, prototype and the window object are likewise disabled. To disable this on a per-script basis, configure this form and add the "Isolate script" field.

To disable this feature for all new globally-scoped client-side scripts set the system property "glide.script.block.client.globals" to false..

Check out this blog,

https://community.servicenow.com/community?id=community_blog&sys_id=c5c46364dbba6b007d3e02d5ca9619cb

 

https://www.servicenow.com/community/developer-forum/isolate-script/m-p/1459302

*************************************************************************************************************
If my response proves useful, please indicate its helpfulness by selecting " Accept as Solution" and " Helpful." This action benefits both the community and me.

Regards
Dr. Atul G. - Learn N Grow Together
ServiceNow Techno - Functional Trainer
LinkedIn: https://www.linkedin.com/in/dratulgrover
YouTube: https://www.youtube.com/@LearnNGrowTogetherwithAtulG
Topmate: https://topmate.io/atul_grover_lng [ Connect for 1-1 Session]

****************************************************************************************************************

Vishal Birajdar
Giga Sage

Hello @Aniket Gaurikar 

 

Below link might help you ...::

https://docs.servicenow.com/bundle/washingtondc-application-development/page/script/client-scripts/c...

 

New client scripts are run in strict mode, with direct DOM access disabled. Access to jQuery, prototype, and the window object are also disabled. To disable this on a per-script basis, configure this form and select the Isolate script check box. To disable this feature for all new globally-scoped client-side scripts set the system property glide.script.block.client.globals to false.

 

 

Vishal Birajdar
ServiceNow Developer

I know one thing, and that is that I know nothing.
- Socrates

Robbie
Kilo Patron
Kilo Patron

Hi @Aniket Gaurikar,

 

Check this article from Alikutty which describes the isolate script functionality in detail.

 

https://www.servicenow.com/community/developer-blog/isolate-script-in-london/ba-p/2275821

 

To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Helpful.

 

Thanks, Robbie

Sohail Khilji
Kilo Patron
Kilo Patron

Hi @Aniket Gaurikar ,

 

This is very rarely used and needs lot of causion before use. It's generally not recommend to use. This checkbox is used when you playing with Data objects. I hope this helps..

 

Read this for more info :

https://www.servicenow.com/community/developer-blog/isolate-script-in-london/ba-p/2275821

 

I hope this helps...


☑️ Please mark responses as HELPFUL or ACCEPT SOLUTION to assist future users in finding the right solution....

LinkedIn - Lets Connect