title: Visual Studio templating - conditionally hide parameter
body: <p>I am attempting to create a custom Visual Studio project template and I have a template.json. What I am trying to achieve is to hide / disable the <code>DoStuff</code> parameter from the Visual Studio create project wizard if another parameter (in my case, <code>ProjectType</code>) was equal to something specific. It would essentially be something like the <code>Docker OS</code> parameter from the default Visual Studio API template.</p>
  <p><a href="https://i.stack.imgur.com/ewhOJ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ewhOJ.png" alt="VS create project wizard" /></a></p>
  <p>As you can see, by default the dropdown (in my case, it would be a checkbox) is hidden / disabled, but if I check <code>Enable Docker</code>, it can be selected.</p>
  <p>Below is my current <code>template.json</code> file which I can't seem to get right to have this feature.</p>
  <pre class="lang-json prettyprint-override"><code>{
      &quot;$schema&quot;: &quot;http://json.schemastore.org/template&quot;,
      &quot;symbols&quot;: {
        &quot;ProjectType&quot;: {
          &quot;type&quot;: &quot;parameter&quot;,
          &quot;datatype&quot;: &quot;choice&quot;,
          &quot;choices&quot;: [
            {
              &quot;choice&quot;: &quot;Console&quot;
            },
            {
              &quot;choice&quot;: &quot;API&quot;
            }
          ],
          &quot;defaultValue&quot;: &quot;API&quot;,
          &quot;description&quot;: &quot;The type of the project you are building.&quot;
        },
        &quot;DoStuff&quot;: {
          &quot;type&quot;: &quot;parameter&quot;,
          &quot;datatype&quot;: &quot;bool&quot;,
          &quot;defaultValue&quot;: &quot;false&quot;,
          // hide if ProjectType == API
        }
      }
  }
  </code></pre>
  <p>I tried to combine it with <code>ide.host.json</code> to achieve this, but it's not working at all.</p>
  <pre class="lang-json prettyprint-override"><code>{
      &quot;$schema&quot;: &quot;https://json.schemastore.org/ide.host.json&quot;,
      &quot;defaultSymbolVisibility&quot;: true,
      &quot;order&quot;: 2,
      &quot;icon&quot;: &quot;icon.png&quot;,
      &quot;symbolInfo&quot;: [
        {
          &quot;id&quot;: &quot;DoStuff&quot;,
          &quot;isVisible&quot;: &quot;(ProjectType == \&quot;API\&quot;)&quot;
        }
      ]
  }
  </code></pre>