-
vue error 해결법 : v-html 에서 css 적용안될 때Error Handling 2021. 3. 16. 23:12반응형
v-html 을 이용하여 다양한 html 코드를 string 방식으로 입력받을 때 html 코드는 잘 입력이 되지만
css 는 적용이 안될 때가 있다.
이럴 때에는 보통 <style> 부분에서 잘못될 가능성이 많은데
아래와 같이 style 에 범위를 scoped로 한정하여 지정한 것은 아닌지 확인한다.
<style lang="scss" scoped> .test { color: red; } </style>
이 경우 아래와 같이 scoped 를 풀어주면 자연스럽게 css가 적용된다.
<style lang="scss"> .test { color: red; } </style>
반응형'Error Handling' 카테고리의 다른 글
윈도우 10 블루투스 사라짐 해결법 : bluetooth 가 꺼져 있습니다 (0) 2021.04.11 text-align: center 작동하지 않을 때 해결법 (0) 2021.03.22 jupyter notebook 에서 cv2.imshow() 사용시 응답없음 오류 나는경우 해결법 (3) 2021.03.14 vue error 해결법 : PostCSS received undefined instead of CSS string (0) 2021.02.08 vue error 해결법: Syntax Error: TypeError: this.getOptions is not a function (1) 2021.02.08