Hi, has anyone tried to used a moments.js plug-in ...
# suitescript
b
Hi, has anyone tried to used a moments.js plug-in before successfully? I can't make it work since NS is bugging me about the following error
Copy code
{
  "type": "error.SuiteScriptModuleLoaderError",
  "name": "{stack=[Ljava.lang.Object;@2d8e7060, toJSON={}, name=MODULE_DOES_NOT_EXIST, toString={}, id=, message=Module does not exist: /moment.js, TYPE=error.SuiteScriptModuleLoaderError}",
  "message": "",
  "stack": []
}
I'm using moments.js itself for a while now. It seems that the moments plug-in itself is trying to load moment via a require. What should be done to make it work?
b
that looks to be moment-business, not moment
normally id tell you to get a more up to date version of the library, but it looks like the build tooling is wrong and missing dependencies
so you have to deal with the annoyance of finding those dependencies yourself
👍 1