자바스크립트로 사용자 브라우저 체크하기navigator.userAgent 사용 indexOf()를 활용하는데 > -1 도 되고 != 1 도 가능 const browserCheck = () => { const userAgent = navigator.userAgent.toLowerCase(); if (userAgent.indexOf("edge") > -1){ return "edge"; } else if (userAgent.indexOf("whale") > -1){ return "whale"; } else if (userAgent.indexOf("chrome") > -1){ return "chrome"; } else if (userAgent.indexOf("firefox") > ..
HTML CSS.menu-wrap .menu{flex-wrap: nowrap;}.menu-wrap .menu .item{width: calc((100% - 18px)/4);margin-left: 0;margin-top: 0;}.menu-wrap .menu .item ~ .item{margin-top: 0;}.menu-wrap .menu .item a + a{margin-top: 6px;} javaScriptif( $('.swiper-menu .swiper-slide').length > 1 ) { $('.s..
HTML tab1 tab2 tab 1 content tab 2 content CSS.tab_cnt{display: none;} javaScript// tab event const tabMenu = document.querySelectorAll(".tabs li"); const tabBtn = document.querySelectorAll(".tab_link"); const tabCont = document.querySelectorAll(".tab_cnt"); tabBtn.forEach(function (e) { e.addE..
자바스크립트로 셀렉트박스 만들기여러개 만들어 공통 소스 사용하고 클래스와 data 값으로 구분 ㅇㅇㅇ님 select1 select2 Default selectA selectB selectC let orderBrand = null;function initSelectLabel(){ const label = document.querySelectorAll('.label'); label.forEach(function(e){ lb.addEventListener('click', e => { let selectList = lb.nextElementSibling; let selectI..
회사에서 git을 사용하다가오래전 stash 해둔 내역을 git stash apply 했다가 깃이 충돌했다 아래와 같이 뜸committing is not possible because you have unmerged files 충돌 원인은 원격(remote)에는 이미 삭제하고 없는 파일이git stash로 불러와졌기 때문 파일 삭제도 안되고 커밋도 안되고 아무것도 안되는 상황이 되었다 먼저 git status 로 충돌 내역 확인 unmerged paths 이렇게 뜨면 깃이 충돌된 것,, 나의 경우 아래와 같이 떴다unmerged paths:use "git add/rm ..." as appropriate to mark resolutionuse "git restore --staged ..." to un..

