You can add text placeholders to sheet names and pass the sheet name dynamically, as shown in the example below.
Conditional sheets
You can hide/remove sheets from your template by passing empty value to dynamic sheet name. All of sheet content will be removed from output document (including tables and objects embeeded into page)
You need to pass:
Empty value
False value
No value (null or undefined)
To hide sheet with dynamic placeholder conditionally from output document