Does anyone know why client scripts still can't be...
# suitescript
t
Does anyone know why client scripts still can't be configured with SS 2.1 but library files for those same client scripts can be? Its just annoying to have to remember to use var for client scripts and let for everything else
s
That is exactly why I am not using 2.1 currently.
s
I didn't know that 2.0 client scripts could use 2.1 modules/libraries. Maybe just put all of the code in a 2.1 module, and have the 2.0 client script do nothing other than call the entry point in that library?
👍 1
e
I currently just put my Client Scripts at
2.x
and continue using
2.1
syntax
t
Anytime I try to use 'let' and 2.x it blows up on me? Does it work for you?
e
Yes
"blows up" how/when?
s
Is it Netsuite complaining, or the browser?
t
message has been deleted
In SDF its netsuite validation I think complaining
e
This is running just fine in a Prod account right now
t
How are you updating the file?
e
I use WebStorm and the SDF CLI
t
weird
mine always marks using a 'let' as a syntax error
also 👍 for SDF. Love that thing. Need to get up to date with the CLI tool
e
I've only seen that same error when uploading the file manually to NS
t
yeah i know depending on how you upload the file it can skip netsuite validation and just update the file. If you save over a file in the file cabinet I think it skips it. Probably some difference like that that comes from SDF vs CLI SDF
s
Was the script record already there in the account and you are trying to make it 2.1 afterwards, doesn't that cause issues? I believe the validater notes the SS version on creation of the script record.
e
It is - for some reason - very difficult to update the version after creation. I have not been able to figure out a consistent way to do so
j
Is this issue browser specific? Since Clientscript is dealt in the browser, can that be a problem? Please correct me if I'm mistaken.
t
@Sandii I have been able to switch UE's back and foward from 2.0 to 2.1 with relative ease. I think at first there was a bug but its been fixed at least for server side scripts
👍 1