소개
게시글
질문&답변
2020.04.29
error 'index' is defined but never used no-unused-vars 가 나옵니다.
답변 주셔서 감사합니다. 그런데 기능 추가한것들중에서 체크아이콘을 클릭하면 아무런 반응이 일어나지 않습니다.
- 2
- 4
- 2.6K
질문&답변
2020.04.28
error 'index' is defined but never used no-unused-vars 가 나옵니다.
혹시몰라 전체소스 올려드릴게용 v-for =" (todoItem , index ) in todoItems " v-bind :key =" todoItem. item " class ="shadow" > class ="checkBtn fas fa-check" v-bind :class =" { checkBtnCompleted : todoItem. completed } " v-on :click =" toggleComplete (todoItem , index) " > v-bind :class =" { textCompleted : todoItem. completed } " > {{ todoItem. item }} class ="removeBtn" v-on :click =" removeTodo (todoItem , index) " > class ="fas fa-trash-alt" > export default { data : function (){ return { todoItems : [] } } , methods : { removeTodo : function (todoItem , index){ localStorage . removeItem (todoItem) ; this . todoItems . splice (index , 1 ) ; } , toggleComplete : function (todoItem , index){ todoItem. completed = !todoItem. completed ; localStorage . removeItem (todoItem. item ) ; localStorage . setItem (todoItem. item , JSON . stringify (todoItem)) ; } } , created : function () { if ( localStorage . length > 0 ){ for ( var i= 0 ; i localStorage . length ; i++){ if ( localStorage . key (i) !== 'loglevel:webpack-dev-server' ){ this . todoItems . push ( JSON . parse ( localStorage . getItem ( localStorage . key (i)))) ; } } } } } scoped > ul { list-style-type : none ; padding-left : 0 px ; margin-top : 0 ; text-align : left ; } li { display : flex ; min-height : 50 px ; height : 50 px ; margin : 0.5 rem 0 ; padding : 0 0.9 rem ; background : white ; border-radius : 5 px ; } . removeBtn { margin-left : auto ; color : #de4343 ; } . shadow { box-shadow : 5 px 10 px 10 px rgba ( 0 , 0 , 0 , 0.03 ) ; } . checkBtn { line-height : 45 px ; color : #63acde ; margin-right : 5 px ; } . checkBtnCompleted { color : #b3adad ; } . textCompleted { text-decoration : line-through ; color : #b3adad ; }
- 2
- 4
- 2.6K
질문&답변
2020.04.17
VueCLI 버전 질문드립니다.
intellij 에도 vscode 에 있는 vetur같은 플러그인이 있을까요? 인텔리제이 에는 veutr이 없는것 같아서요. `vue` 나 `scf`같은 단축키가 안먹히네요.
- 1
- 4
- 434
질문&답변
2020.04.16
VueCLI 버전 질문드립니다.
빠른답변 감사합니다.!
- 1
- 4
- 434