Chaning the content of template file before deploying app-sync

Can we change the content of template file before deploy aws appsync?
For Example:
We need to use some value or codes from a json file in our vtl file. But since vtl files does not support feature. So we are thinking

“We should add a placeholder at places where we need that code, and during deployment, we replace those placeholder with the actual code in the generated pacakge, and then serverless will deploy it”

.

Why we are looking for such thing is mentioned in detailed here on Stackoverflow question