Created
December 22, 2022 22:40
-
-
Save naturalett/f53bb25e4889645a4111d9abbdcbc35a to your computer and use it in GitHub Desktop.
renderTemplate
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import groovy.text.StreamingTemplateEngine | |
def call(input, variables) { | |
def engine = new StreamingTemplateEngine() | |
return engine.createTemplate(input).make(variables).toString() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment