How to use encoding.js

KS18
Giga Guru

I want to create a CSV file in SJIS with a script.
In doing so, I want to use the encode.js library.
https://github.com/polygonplanet/encoding.js
Is there a way to use such a library with ServiceNow?

5 REPLIES 5

jaheerhattiwale
Mega Sage
Mega Sage

@KS18 Yes there is way to include the JS libraries in servicenow.

 

Create a UI script and add the JS code to it. Then in service portal widget you can add the ui script as dependency.

 

Please try this.

 

Please mark correct or helpful answer based on impact.

Please mark the answer as correct or helpful based on impact
ServiceNow Community Rising Star, Class of 2023

@jaheerhattiwale 

Thank you for your comment.
I want to use this library in scriptInclude.

 

@KS18 script include is server side script right. JS might be client side code.

Please mark the answer as correct or helpful based on impact
ServiceNow Community Rising Star, Class of 2023

@jaheerhattiwale 

Is it not possible to put the library code in a separate ScriptInclude?