Загрузка...

Using JavaScript Smooth Scrolling [LIVE CODING WITH PAYLOAD CMS & NEXTJS]

Learn to build full-stack apps with Payload — https://nlvcodes.com/courses/payload-essentials Reminder, this is not a step-by-step tutorial; it’s a live-coding and debugging session. Here's a link to the repo: https://github.com/midlomarketing/midlomark

In this live coding session, I explore how to refine my table of contents navigation by implementing smooth scrolling and removing ID anchors from the URL bar. We'll dive into JavaScript's scrollTo function, event listeners, and how to improve the user experience.

Topics Covered:
- Fixing table of contents scrolling issues
- Removing pound signs from URLs
- Using preventDefault to control link behavior

Subscribe for more web development tips!

Chapters:
00:00 - Introducing the live stream and table of contents functionality
01:47 - Setting up preventDefault in a clickHandler
03:22 - Setting up a smooth scroll using React on a table of contents
04:58 - Changing gears to use useEffect instead
06:35 - Confirming the functionality works

#webdevelopment #payloadcms #javascript

Видео Using JavaScript Smooth Scrolling [LIVE CODING WITH PAYLOAD CMS & NEXTJS] канала Nick Vogel
Яндекс.Метрика
Все заметки Новая заметка Страницу в заметки
Страницу в закладки Мои закладки
На информационно-развлекательном портале SALDA.WS применяются cookie-файлы. Нажимая кнопку Принять, вы подтверждаете свое согласие на их использование.
О CookiesНапомнить позжеПринять