rryu09

  • 홈
  • 태그
  • 방명록

themeProvider 1

useTheme vs theme import

팀원이 코리 달아줘서 알게 된 내용!theme 를 context 로 themeProvider 로 전달해서 사용하고 있을 때, styled-component 안에서는 props.theme 해서 접근해 사용할 수 있었다.그런데 styled-component 밖 로직단에서 상태별로 분기해 색상을 변경해야 할 때는 어떨까?props로 사용할 수 없으니 나는 export 된 theme 를 직접 사용했었다.이때 useTheme의 존재를 알게 되었는데 ..https://emotion.sh/docs/theming#usetheme Emotion – Theming(Edit code to see changes)emotion.sh  가장 큰 차이점은 현재 theme 를 반영할 수 있다는 점인가보다. 이게 바뀌면 적용된 컴포넌..

Dev/React 2024.11.18
이전
1
다음
더보기
프로필사진

rryu09

  • 분류 전체보기 (45)
    • ETC (4)
      • 기록 (3)
    • Dev (2)
      • React (4)
      • React Native (0)
      • JS (0)
      • 졸프 (3)
      • Next.js (0)
      • Cloud (1)
      • Algorithm (28)
      • 리팩토링 (2)

Tag

2차원, Algorithm, API, Audio, Autolayout, babel, BFS, colab, compiler, dfs, DICTIONARY, emotion, es6, figma, FP, Google cloud API, GPT, heapq, image, JavaScript, jest, Knight, lcp, leetcode, Lighthouse, mst, my.cnf, MySQL, Network, next.js, node_modules, npm, object detection, Package Manager, PM, PQ, priority, priority queue, Python, react, storybook, SVG, swc, TfLite, theme, themeProvider, translate, Tree, TTS, TypeScript, UI, usetheme, Word Ladder, Yarn, yarn-berry, yolov5, 개발, 개발자, 공통컴포넌트, 그래프, 누적합, 달팽이, 디자인, 렌더링, 리액트, 리팩토링, 면접, 방문배열, 배열, 배포, 백준, 백트래킹, 부모찾기, 성능개선, 스도쿠, 스토리북, 아이콘, 알고리즘, 오블완, 위상정렬, 이분 그래프, 졸프, 직장인, 최단경로, 최대 증가 부분 수열, 최소 스패닝 트리, 최종합격, 취준, 컴파일러, 컴포넌트, 코딩테스트, 크루스칼, 테스팅, 투포인터, 튜토리얼, 티스토리챌린지, 파이썬, 폰트, 폰트 추천, 프론트엔드,

최근글과 인기글

  • 최근글
  • 인기글

최근댓글

공지사항

페이스북 트위터 플러그인

  • Facebook
  • Twitter

Archives

Calendar

«   2025/07   »
일 월 화 수 목 금 토
1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30 31

방문자수Total

  • Today :
  • Yesterday :
WEB GitHub

Copyright © Kakao Corp. All rights reserved.

티스토리툴바