title: VS Code snippet with multiple transforms
body: <p>I am trying to make a snippet that will take clipboard contents (the text of a heading in a <code>markdown</code> document) and transform it into a link to that section. For example, if my clipboard contains: <code>Some Heading - 20191107</code> then I want the following to be output:</p>
  
  <pre><code>[Some Heading - 20191107](filename.md#some-heading---20191107)
  </code></pre>
  
  <p>Here is my snippet <code>VS Code</code> for <code>markdown</code> so far:</p>
  
  <pre><code>    "link to this section": {
          "prefix": "isection",
          "body": [
              "[${1:${CLIPBOARD}}](${TM_FILENAME}#${CLIPBOARD/ /-/g})"
          ],
          "description": "Insert link to section whose heading text is in the clipboard"
      }
  </code></pre>
  
  <p>This has the first transform, but what I cannot figure out is how to nest multiple transforms:</p>
  
  <ul>
  <li>Replace all space with a hyphen.</li>
  <li>Change all to lower case.</li>
  <li>Remove any characters matching <code>[^a-z0-9-]</code></li>
  </ul>
  
  <h1>Test Case</h1>
  
  <p>To clarify my test case for @Mark, in a <code>markdown</code> document in <code>VS Code</code>, I make a section heading such as:</p>
  
  <pre><code># 20191107 - @#$%^&amp; This is a section - 20191107
  </code></pre>
  
  <p>I then copy the text <code>20191107 - @#$%^&amp; This is a section - 20191107</code> and run the snippet you fixed up for me. What it outputs is:</p>
  
  <pre><code>[20191107 - @#$%^&amp; This is a section - 20191107](tips.tech.git.md#20191107----this-is-a-section---20191107)
  </code></pre>
  
  <p>Which is a valid link to the heading!</p>