GoConqr has a new look! Let us know what you think.

Flashcards

Context API

Wanderson Vicente Portuguese 2 cards

Cards in this deck (2)

  1. 1Criação básica do CONTEXT API// /src/context/ThemeContext.ts
    import { createContext } from 'react';
    const ThemeContext = createContext();
    export default ThemeContext;
  2. 2Tipando o CONTEXT API// ...
    type ThemeContextType = {
    theme: 'dark' | 'light';
    };
    const ThemeContext = createContext({} as ThemeContextType);

Information

Description
Context API
Views
0
Rating

Feedback

What is it about?

What do you think of the new look?

How do you like it?