generated from vtex-apps/react-app-template
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
12 additions
and
1 deletion.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ Utility for generating CSS handles for store components. | |
|
||
🚧 Under Construction 🚧 | ||
|
||
### Usage | ||
## Usage | ||
|
||
```tsx | ||
import React, { FunctionComponent } from 'react' | ||
|
@@ -35,3 +35,14 @@ const Component: FunctionComponent = () => { | |
) | ||
} | ||
``` | ||
|
||
### Options | ||
|
||
- `migrationFrom`: Adds additional CSS handles for cases where a component is migrating from another app. | ||
|
||
#### Usage: | ||
```tsx | ||
const CSS_HANDLES = ['container'] | ||
const handles = useCssHandles(CSS_HANDLES, { migrationFrom: '[email protected]' }) | ||
// Returns { container: 'vtex-current-app-0-x-container vtex-store-components-2-x-container' } | ||
``` |