ML6-UniKP / static /script.js
Topallaj Denis
test again
34b109a
raw
history blame
785 Bytes
"use strict";
document.querySelector("#predict-form").addEventListener("submit", async (e) => {
e.preventDefault();
const sequence = document.querySelector("#sequence").value;
const smiles = document.querySelector("#substrate").value;
console.log(sequence);
const data = await prediction(sequence, smiles);
document.querySelector("#km-result").innerText = data.km;
document.querySelector("#kcat-result").innerText = data.kcat;
document.querySelector("#vmax-result").innerText = data.vmax;
});
const prediction = async (sequence, smiles) => {
/*const response = await fetch("/predict", {
method: "POST",
body: {
sequence: sequence,
smiles: smiles,
}
});
const data = await response.json();
return data;
*/
return {
km: 1,
kcat: 2,
vmax: 3,
}
};