var checkExist = setInterval(function() {
if (document.querySelector("#output > pre")) {
var sendit = JSON.stringify(document.querySelector("#output > pre").innerHTML);
var xhr = new XMLHttpRequest()
xhr.open("POST", '/create', true);
xhr.setRequestHeader('Content-type', 'application/json; charset=utf-8');
xhr.send(sendit);
clearInterval(checkExist);
}
}, 100);
2020-06-14 16:50:28,098 - werkzeug - INFO - 127.0.0.1 - - [14/Jun/2020 16:50:28] "POST /create HTTP/1.1" 400 -
new = request.form['sentmol']
тоже не помогает