Most code I see here should be `const`, not `var` ...
# suitescript
s
Most code I see here should be
const
, not
var
or
let
👍 2
z
How do you understand this
Copy code
const rec=context.record;
rec.setValue(...);
s
const variables cannot be reassigned, but const does not mean immutable
z
Yes, I understand that, just point to an confused situation (at least for me)... Don't get me wrong, since 2.1 I usually use const for record object. But, sometimes I like to make difference between "read-only" constant and variable objects. I agree with @Shawn Talbert most suitescriot code could be const instead let and var
d