elixFormsAPI - update syntax and add prepare global function

This commit is contained in:
2026-02-23 10:28:54 +01:00
parent fd3d0da848
commit 98a6019e32
51 changed files with 1716 additions and 3379 deletions
@@ -48,8 +48,9 @@ runtime:
scripts:
- type: before-request
code: |-
const { prepareEftlDocument } = require("./elixFormsJs.js")
// Copy-pasta your EFTL document below inside the template literals (`)
var eftlDocumentToBeProcessed = String.raw`
prepareEftlDocument(String.raw`
[EFTL][HEADER name="trimDocument" value="true" type="boolean" /]
[VAR name="newLine" type="string"][VALUE_OF varname="crlf" /][/VAR]
[VAR name="stringSeparated" type="string"][% stringSeparated = "xyz#abc#def"; %][/VAR]
@@ -76,11 +77,7 @@ runtime:
[%= newLine %]
[%= complex %]
[/EFTL]
`;
var base64EncodedDocument = btoa(eftlDocumentToBeProcessed);
bru.setVar("elixBase64EftlDocument", base64EncodedDocument);
`);
settings:
encodeUrl: true