D
D
danhab2017-10-14 22:40:12
JavaScript
danhab, 2017-10-14 22:40:12

How to remove the bottom scroll bar, or disable movement?

When the left bar is open, you can tap on it and move it around the screen, so you need to fix it, is it possible to somehow remove this bar or disable horizontal scrolling altogether?

Screen

59e268014ed7c000357389.jpeg

Answer the question

In order to leave comments, you need to log in

3 answer(s)
D
Dima Polos, 2019-07-12
@testkeyc

In short, everything worked for me. In the example, you don't have a curly brace that closes the body of the function. At the same time, without window.onload, although it would be better with it, but then do it through addEventListener and listening to load and listening to click.
PS: pay attention to one more error in the console.

V
vit134, 2019-07-12
@vit134

window.toggleMenu = function() {// code here}
But in general, it's better to hang an event handler on this element

const toggleMenu = function() {
  if (menu.className === "nav__list") {
    menu.classList.add("open");
  } else {
    menu.className = "nav__list";
  }
};

document.querySelector(".hamburger").addEventListener("click", toggleMenu);

S
Stalker_RED, 2017-10-14
@Stalker_RED

overflow x

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question