Answer the question
In order to leave comments, you need to log in
How can Javascript specify an additional condition depending on the width of the browser?
How to make a condition in JS be executed only at a certain browser width?
$(window).load(function() {
$('.nav_slide_button').click(function() {
$('.pull').slideToggle();
});
});
<nav class="pull">
<ul class="nav navbar-nav navbar-right">
<li><a href="#intro">1-ый пункт</a></li>
<li><a href="#contact">Контакты</a></li>
</ul>
</nav>
@media screen and (max-width:991px) {
.pull { display: none; }
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question