clientScriptModulePath is relative
# suitescript
b
clientScriptModulePath is relative
b
My user event script and client script are in the same directory. I've tried the path "client_script.js", but I get "Module does not exist".
b
what does your code look like?
b
The very first line in my UE's beforeLoad function is:
Copy code
context.form.clientScriptModulePath = 'client_script.js';
And that's where the script errors out
b
and the name of your client script?
b
It's just lowercase letters and underscores with ".js" at the end
For example: client_script.js
b
and you havent dont anything with require configs?
b
No, I didn't know you could
b
meh, try being explicit about the relative part ./client_script.js
b
Specifically, the error message says "Module does not exist: /client_script.js". I did not add a "/" to the beginning
b
i double down on the ./
b
That worked 🙂
Thanks for your help
182 Views