ConditionalWrapper
ready
This page may be removed. Primer plans to move all Rails component documentation to Lookbook.
Description
Conditionally renders a component around the given content. If the given condition is true, the component will render around the content. If the condition is false, only the content is rendered.
Arguments
| Name | Default | Description |
|---|---|---|
condition | BooleanWhether or not to wrap the content in a component. | |
component | ClassThe component class to use as a wrapper, defaults to | |
base_component_arguments | HashThe arguments to pass to the component. |