dev #3
@@ -13,7 +13,7 @@
|
||||
onsubmit={async (e) => {
|
||||
e.preventDefault();
|
||||
// console.log(e.target[0].value);
|
||||
console.log($url);
|
||||
// console.log($url);
|
||||
const req = { longUrl: input.value };
|
||||
try {
|
||||
const res = await fetch(`${$url}/url/`, {
|
||||
@@ -22,7 +22,7 @@
|
||||
});
|
||||
if (res.ok) {
|
||||
const data = await res.json();
|
||||
console.log(data.shortUrl);
|
||||
// console.log(data.shortUrl);
|
||||
popup = data.shortUrl;
|
||||
}
|
||||
} catch {
|
||||
|
||||
Reference in New Issue
Block a user