Leemos el contenido original del index.html
with open(index_html_path, 'r', encoding='utf-8') as f:
html_content = f.read()
Insertamos los botones después de la etiqueta
(si no están ya)if "<button" not in html_content:
html_content = html_content.replace("
Guardamos los cambios en los archivos
with open(app_js_path, 'w', encoding='utf-8') as f:
f.write(app_js_code)
with open(index_html_path, 'w', encoding='utf-8') as f:
f.write(html_content)