gustiti03 / nodejs-quarta

0 stars 0 forks source link

HTML #3

Open gustiti03 opened 3 weeks ago

gustiti03 commented 3 weeks ago

<!DOCTYPE html>

Minha página

Login

Nome

Senha

gustiti03 commented 3 weeks ago

import express from 'express'; import path from 'path';

const app = express(); const port = 5000

app.use(express.urlencoded({ extended: true}))

app.get('/', function(req, res){ const root = path.resolve("./index.html") res.sendFile(root) })

app.post("/login", function(req, res ){ console.log(req.body) })

app.listen(port, function() { console.log("Estou online") })