You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Mixed code using both ES6 and ES5
ES6 Code in router.js const {handleHome, handleStatic,handleRequest, handleError} = require("./handler.js");
ES5 code in router.js
`function router (request, response) {
let baseUrl = request.url;
if (baseUrl === "/") {
// console.log(baseUrl);
handleHome(request, response);
} else if (baseUrl.split('?')[0] === '/submit') {
// console.log(baseUrl);
handleRequest(request,response);
Mixed code using both ES6 and ES5
ES6 Code in router.js
const {handleHome, handleStatic,handleRequest, handleError} = require("./handler.js");
ES5 code in router.js
`function router (request, response) {
let baseUrl = request.url;
if (baseUrl === "/") {
// console.log(baseUrl);
handleHome(request, response);
} else if (baseUrl.split('?')[0] === '/submit') {
// console.log(baseUrl);
handleRequest(request,response);
} else {
// console.log(baseUrl);
handleStatic(request, response);
}
}
`
The text was updated successfully, but these errors were encountered: