JavaScript - Separation of logic layer code from the presentation layer. Using addEventListener

Publicado el: 11 agosto 2022
en el canal de: Miquel Boada Artigas
187
2

When you develop a web application is good practice don't mix the presentation with the logic. In our case, the HTML contains the presentation while the JS file contains the logic. When we add events in the HTML file we're adding logic to the presentation layer. For this motive, is a good practice to move the events to the JS file. This video shows how you can get to this goal. When you change your code, you must be careful to avoid the error "uncaught type error cannot read property 'addeventlistener' of null".


En esta página del sitio puede ver el video en línea JavaScript - Separation of logic layer code from the presentation layer. Using addEventListener de Duración hora minuto segunda en buena calidad , que subió el usuario Miquel Boada Artigas 11 agosto 2022, comparta el enlace con amigos y conocidos, en youtube este video ya ha sido visto 187 veces y le gustó 2 a los espectadores. Disfruta viendo!