- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-23-2020 06:32 AM
Hello all,
I have some standard JavaScript functions that i want to bundle them into a single repository/file instead of using them in the respective client scrips.
Question is, Is there a place/location where i can store all the standard JS functions so i can call them from any of my client/UI policies?
Thanks,
KP
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-23-2020 08:35 AM
Infact, glide ajax serves as purpose to improve performance.
You can use async glide ajax as well.
Regards,
Sachin

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-23-2020 08:18 AM
You can create script include to store all my JS library functions so that you can call them from client script using Glide Ajax.
Check below
Regards,
Sachin

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-23-2020 08:21 AM
Just as Sachin stated, the only way to do this is to have a script include that you call via glide ajax that contains all of your code. Unfortunately, there is not a client-side equivalent for this functionality.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-23-2020 08:26 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-23-2020 08:31 AM
Thanks for your answers.
Isn't Script Include for server development. So every time I want to call a client side javascript function, you are saying call the function which resides on the server side and ServiceNow needs to make a trip to server? Isn't that a performance bottleneck?