The CreatorCon Call for Content is officially open! Get started here.

ES6 on global application

Snow Tomcal
Tera Expert

Hi.

I am Using ServiceNow Vancouver patch 4 and I would like to know if there is a way to use ES12 in the global application. 

I want to use let and other new features in the global application.

Thanks!

  

4 REPLIES 4

Maik Skoddow
Tera Patron
Tera Patron

Hi @Snow Tomcal 

until now ES12 is only allowed for custom scoped application but not for global. 

Please refer to page https://docs.servicenow.com/bundle/vancouver-application-development/page/script/JavaScript-engine-u... for more information.

Maik

Hi,
will it be available to use ES12 in global application in the next release?

At the moment it does not even work for client scripts.

Hi @Snow Tomcal 

in Client Scripts you can use whatever you want as these scripts are executed in the browser and by its engine and not by ServiceNow!

And regarding your question: There is no official statement available when ES12 will be available for global, but I know that it will come definitely.

Maik

From global es5 script include can I call a function from another script include written in es12?
As I tried - it seems external script include is interpreted with es5 js engine (and fails due to missing feature) even if this script created in es12 powered scope.
I made it "Accessible from" but it seems snow currently can't switch JS engines on the fly?