Skip to content
Snippets Groups Projects
main.js 640 B
Newer Older
  • Learn to ignore specific revisions
  • import $ from './globals';
    import MobileMenu from './components/mobile-menu';
    
    import Search from './components/search';
    
    import MobileSearch from './components/mobile-search';
    
    
    $(function () {
        $(MobileMenu.selector()).each((index, el) => {
    
            new MobileMenu($(el), $('.js-mobile-menu-close'), $('.header__menus--mobile'), $('.header__search'));
    
        $(Search.selector()).each((index, el) => {
            new Search($(el), $('.header__search'));
    
    
        $(MobileSearch.selector()).each((index, el) => {
            new MobileSearch($(el), $('.header__menus--mobile'), $('.header__search'), $('.js-search-toggle'));
        });