title: How to remove text from Google Docs using App Scripts?
body: <p>I just recently built a series of documents using Google Script and Form/Sheets. </p>
  
  <p>The document generates in Google Docs via the script, using the data provided in the initial form.</p>
  
  <p>The setup is basically as below:</p>
  
  <h2>Conditions to pass</h2>
  
  <ul>
  <li>Class: {{CLASS}}</li>
  <li>Minimum Grade: {{MINIMUM_GRADE}} / 10</li>
  <li>Minimum attendance: {{ATTENDANCE_PERC}}% with a minimum of {{ATTENDANCE}} attendances over the semester</li>
  </ul>
  
  <p>Where the form input is placed between those {{ }}.</p>
  
  <p><strong>Currently</strong>, this case would show something like: </p>
  
  <ul>
  <li>Class: 3rd Year</li>
  <li>Minimum Grade: Not Applicable / 10</li>
  <li>Minimum attendance: 70% with a minimum of 15 attendances over the semester</li>
  </ul>
  
  <p>But I would like: </p>
  
  <ul>
  <li>Class: 3rd Year</li>
  <li>Minimum attendance: 70% with a minimum of 15 attendances over the semester</li>
  </ul>
  
  <p>Is there any way that I can make Google Script automatically remove, any of the the bullet point, for example here "Minimum Grade" if the answer to this question is "Not Applicable"?</p>