Created
September 11, 2019 03:01
-
-
Save erickhaendel/cbebc07518936a2e14d427e87dc3f939 to your computer and use it in GitHub Desktop.
Named Export Example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Imports | |
// Ex. importando um named export | |
import { MyComponent } from "./MyComponent"; | |
// Ex. importando multiplos named exports | |
import { MyComponent, MyComponent2 } from "./MyComponent"; | |
// Ex. Alterando o nome do modulo importado usando "as": | |
import { MyComponent2 as MyNewComponent } from "./MyComponent"; | |
// Arquivo com os componentes para exportação | |
// Exports do arquivo ./MyComponent.js | |
export const MyComponent = () => {} | |
export const MyComponent2 = () => {} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment