input: def generate_html_form(form_id: str) -> str:
      """
      Generate a basic HTML form using JavaScript to submit a user's city and submit the details to the server.
      
      :param form_id: The id of the form to be generated
      :return: A string containing the HTML form and JavaScript code to handle form submission
      
      >>> generate_html_form('myForm')
      '<form id="myForm" onsubmit="submitForm(event)">\\n  City:<br>\\n  <input type="text" name="city"><br>\\n  <input type="submit">\\n</form>\\n\\n<script>\\nfunction submitForm(event) {\\n  event.preventDefault();\\n\\n  const form = document.getElementById('myForm');\\n  const city = form.querySelector('input[name=\"city\"]').value;\\n\\n  const data = { city: city };\\n\\n  const options = {\\n    method: 'POST',\\n    body: JSON.stringify(data),\\n    headers: {\\n      'Content-Type': 'application/json'\\n    }\\n  };\\n\\n  fetch('/my-api/submit-form', options)\\n    .then(response => response.json())\\n    .then(data => {\\n      console.log(data);\\n    });\\n}\\n</script>'
      """
      
      form_html = f'<form id="{form_id}" onsubmit="submitForm(event)">\n  City:<br>\n  <input type="text" name="city"><br>\n  <input type="submit">\n</form>\n\n<script>\nfunction submitForm(event) {{\n  event.preventDefault();\n\n  const form = document.getElementById(\'{form_id}\');\n  const city = form.querySelector(\'input[name="city"]\').value;\n\n  const data = {{ city: city }};\n\n  const options = {{\n    method: \'POST\',\n    body: JSON.stringify(data),\n    headers: {{\n      \'Content-Type\': \'application/json\'\n    }}\n  }};\n\n  fetch(\'/my-api/submit-form\', options)\n    .then(response => response.json())\n    .then(data => {{\n      console.log(data);\n    }});\n}}\n</script>'
      
      return form_html
output:     form_html = f'<form id="{form_id}" onsubmit="submitForm(event)">\n  City:<br>\n  <input type="text" name="city"><br>\n  <input type="submit">\n</form>\n\n<script>\nfunction submitForm(event) {{\n  event.preventDefault();\n\n  const form = document.getElementById(\'{form_id}\');\n  const city = form.querySelector(\'input[name="city"]\').value;\n\n  const data = {{ city: city }};\n\n  const options = {{\n    method: \'POST\',\n    body: JSON.stringify(data),\n    headers: {{\n      \'Content-Type\': \'application/json\'\n    }}\n  }};\n\n  fetch(\'/my-api/submit-form\', options)\n    .then(response => response.json())\n    .then(data => {{\n      console.log(data);\n    }});\n}}\n</script>'
      
      return form_html