Skip to content
Advertisement

Extract variables from text string Javascript

I created a Google Slides that contains a lot of variables. I want to be able to pull all variables I have in there at once to Google Sheets. I’m using apps script to get all of the texts as strings from all shapes in the slides.

I have strings that includes both text and variables.

JavaScript

The desired output is to get an array with all of the variables names.

JavaScript

Thanks!

Advertisement

Answer

JavaScript

Even if you don’t know regexes you can make do with split(). It’s quite hacky though

JavaScript
User contributions licensed under: CC BY-SA
5 People found this is helpful
Advertisement