To read - valentinavolgina2/sunny-hikes Wiki

Node js architecture

https://www.esparkinfo.com/node-js-architecture.html

Long polling

https://www.esparkinfo.com/node-js-long-polling.html https://javascript.info/long-polling

Server Sent Events

https://javascript.info/server-sent-events

https://www.digitalocean.com/community/tutorials/nodejs-server-sent-events-build-realtime-app

WebSocket

https://javascript.info/websocket

Javascript

https://dmitripavlutin.com/javascript-classes-complete-guide/#7-classes-and-prototypes

https://gomakethings.com/how-i-structure-my-vanilla-js-projects/

https://gomakethings.com/creating-a-time-and-date-utility-library-with-javascript/

CSS

https://csslayout.io/

Full Stack JavaScript

https://masteringjs.io/

Useful links

Access localhost from mobile device

https://stackoverflow.com/questions/4779963/how-can-i-access-my-localhost-from-my-android-device

Developer tools in safari on ios

https://www.dummies.com/web-design-development/how-to-use-developer-tools-in-safari-on-ios/#:~:text=1Tap%20the%20Settings%20icon,to%20activate%20the%20Debug%20Console.

Using Google Chrome Console On Any Mobile Device

https://dev.to/dev0x0/using-google-chrome-console-on-any-mobile-device-9ec

Submit form without reloading

$('#reviewForm').on("submit", function(event) {

    `event.preventDefault();`
    `let rating = $( "#rating" ).val()`
    `let body = $( "#messageBody" ).val()`
    `const data = { review: { rating: rating, body: body } }`
    
    `$.ajax({`
        `url: `/places/${hike._id}/reviews`,`
        `type: 'POST',`
        `dataType: 'json',`
        `data: data,`
        `async: true,`
        `success: function (res) {`
            `console.log( res.rating );`
            `console.log( res.body );`
            `console.log(res.author);`
        `},`
        `error: function ( res ) {`
            `console.log( res.responseText );`
            `console.log( res.status );`
        `}`
    `} );`
    
    
`});`

module.exports.validateReview = ( req, res, next ) => { console.log(req.body) const { error } = reviewValidSchema.validate(req.body); if ( error ) {

    `const message = error.details.map( el => el.message ).join( ',' );`
    `console.log( message )`

    `res.writeHead(500, {"Content-Type": "text/plain"});`
    `res.write(message);`
    `res.end();`

`} else {`
    `next();`
`}`

}