Can anyone recommend a NS compatible rules engine ...
# suitescript
e
Can anyone recommend a NS compatible rules engine they've had success with before I roll my own?
m
Curious what you are trying to do exactly @ehcanadian
e
Load a transaction and perform certain actions on it according to various rules. I don't want numerous if/switch statements. I haven't decided on what design pattern I'd like to use. This (https://github.com/cachecontrol/json-rules-engine) is along the lines of what I'd like to use, but it definitely won't load up in NS as is.
m
ah I see. Not sure I have a great recommendation
b
you can try your luck with browserify
actually, taking another look suggests this uses promises and function expressions, which will require at least suitescript 2.1
be extra weary of promises in 2.1, there is no global rejection handler for promises
👍 1