3 ms·
The tooling is just fine for me, DataGrip or not: I wrote a ton of PostgreSQL triggers and utility functions in Javascript thanks to the excellent plv8 (free) e
by sscarduzio 7y ago
The tooling is just fine for me, DataGrip or not: I wrote a ton of PostgreSQL triggers and utility functions in Javascript thanks to the excellent plv8 (free) extension.
Development and unit tests for these functions is as easy as plain Javascript.
- BiteCode_dev 7y ago> Development and unit tests for these functions is as easy as plain Javascript. Since most popular product in the JS world are product to avoid writing Javascript (webpack+babel, typescript, coffeescript, jsx, etc), and plv8 supports non of that nor does it support standard unit tests framework like Jest, I'm not convinced. To make things even worst, remote debugging is not supported anymore: https://github.com/plv8/plv8/issues/131#issuecomment-237711101 https://github.com/plv8/plv8/issues/131#issuecomment-2377111...
- sscarduzio 7y agoI personally this time around, I found no need to even use a framework for unit testing a single javascript function. If I had to do something that feels too complex, I'd write some interfaces in TypeScript to represent the tuples, then implement the function in TS, and compile it into plain JS in order to deploy it to plv8.