1
0
Fork 0
mirror of synced 2024-08-24 22:42:01 +12:00
Commit graph

40 commits

Author SHA1 Message Date
Andrew Kingston
99f9b4bf07 Transform the output of JS expressions to be actual types rather than strings 2022-01-18 13:20:06 +00:00
Andrew Kingston
a0d8bffbc6 Remove the pre-execution validation in string templates to double performance and prevent JS binding issues when mutating context 2021-12-06 17:58:43 +00:00
Andrew Kingston
9b05990418 Update literal helper to return an empty string rather than the string 'undefined' when the value is undefined 2021-11-15 12:25:30 +00:00
mike12345567
be8979e50a Fixing bug #3195 with zero/falsy values not being passed out of bindings. 2021-11-02 16:55:16 +00:00
Andrew Kingston
0539f1a429 Remove optional chaining from string-templates 2021-10-14 13:04:57 +01:00
Andrew Kingston
1bd0897fd8 Block certain browser API's when executing JS in the browser 2021-10-14 12:02:34 +01:00
Andrew Kingston
403f64d1ac Use vm2 for JS execution in node, and a vm polyfill for the browser. Use 2 standalone entrypoints for string-templates depending on env 2021-10-14 11:51:05 +01:00
Andrew Kingston
0dfa108ef5 Prevent executing JS bindings when running in a Node env 2021-10-13 14:37:14 +01:00
Andrew Kingston
4075d0d97c Add one second timeout to execution of JS bindings 2021-10-13 13:44:43 +01:00
Andrew Kingston
7d7c28d967 Fix issue deeply extract falsey values from context while executing JS bindings 2021-10-12 16:13:07 +01:00
Andrew Kingston
d6a1e3d248 Correctly handle JS nullish values by removing forced fallback value of HBS helper 2021-10-12 15:40:01 +01:00
Andrew Kingston
4174b88057 Ensure null or empty values don't cause raw JS to appear when executing JS HBS helper 2021-10-12 15:32:43 +01:00
Andrew Kingston
b06669fe32 Fix inserting bindings manually when using JS 2021-10-11 16:18:20 +01:00
Andrew Kingston
d114b3f1ed Fix bug determining if a binding is JS or not 2021-10-11 15:51:47 +01:00
Andrew Kingston
4fd31b9eac Add JS helper to string templates 2021-10-11 14:53:55 +01:00
mike12345567
38e6956b19 Fixes for #2634 - make sure string templates library handles conversion of raw JSON objects to stringified correctly. 2021-09-17 17:18:52 +01:00
mike12345567
1df459a5bf Fixing issues discovered with hbs escaping. 2021-06-24 11:37:26 +01:00
mike12345567
3ffd340450 Updating date helper to allow timezone capabilites. 2021-06-09 11:44:24 +01:00
mike12345567
1470e601aa Updating date helper to use UTC. 2021-05-27 15:21:00 +01:00
Andrew Kingston
556236ebce Add explicit prettier options 2021-05-04 11:32:22 +01:00
Keviin Åberg Kultalahti
4ec2e7d01f lint:fix 2021-05-03 09:31:09 +02:00
Andrew Kingston
d1be0a58b4 Fix edge case bug where the literal handlebars helper would not work with objects including a dash character 2021-03-16 18:16:56 +00:00
mike12345567
a9dc9f0561 Fixing issue that was breaking linting. 2021-02-04 10:41:25 +00:00
mike12345567
008c9dcbcd Linting and updating helper manifest. 2021-02-04 10:25:04 +00:00
mike12345567
a86b6db772 Quick addition of a duration helper which can be used to create relative humanized date strings. 2021-02-04 10:17:10 +00:00
mike12345567
6fd080269b linting. 2021-02-03 13:56:01 +00:00
mike12345567
9ae53caa4d Removing the use of helper-date which was causing some problems, instead took what we needed of it out of the package and updated to use dayjs instead of moment. 2021-02-03 13:55:33 +00:00
mike12345567
92ab3631ea Adding object and regex helpers as well as a complex test case for forIn. 2021-02-02 14:22:10 +00:00
mike12345567
e82fa5f68a Updating to use budibase helpers. 2021-01-31 11:46:45 +00:00
mike12345567
c8295f0fbd Linting. 2021-01-26 12:43:26 +00:00
mike12345567
bb85078300 Adding a literal helper which can make sure the output of an operation is a literal value. 2021-01-25 18:14:45 +00:00
mike12345567
ebb78a3c29 Updating string templates to have test cases for all the main helpers we want to make use of and adding a readme. 2021-01-25 17:08:21 +00:00
mike12345567
b42677f657 Fixing some issues CI linting found. 2021-01-21 18:08:04 +00:00
mike12345567
5fa18c0280 Linting. 2021-01-21 17:30:51 +00:00
mike12345567
00967985e8 Getting ready to merge with some basic functionality but updates required to client/builder/automations to remove the need for space in hbs statement handling. 2021-01-21 15:50:46 +00:00
mike12345567
ec55655900 Handling undefined/null values in context object for string templates, replacing with empty string. 2021-01-21 13:48:23 +00:00
mike12345567
8ecabc91cc Linting. 2021-01-21 11:32:26 +00:00
mike12345567
a9274f7d86 Adding cleaners which will process and find spaces removing them and fixing them with literal specifiers for handlebars props. Also changing the way cleaners work for the system to make it easier to add them. 2021-01-20 18:12:16 +00:00
mike12345567
4c597ed91a Moving everything over to use the string template library, now just need to escape spaces properly and handle HTML escaping. 2021-01-19 18:44:29 +00:00
mike12345567
3c627d6455 Adding the handlebars library, still need to add testcases to this. 2021-01-18 17:40:19 +00:00