renderFavorites Method
Allow creating an HTMLElement containing the <FavoritePropertyList />
component so it can be added outside of a React component (showCard
is the main expected use)
Note: When using React18, in order to remove the ReactDOM.render
warning you will need to provide the createRoot
function to this function,
the parameter type is intentionally simplified to not depend on React18 type.
renderFavorites(propertyData: PropertyData, orientation?: Orientation, createRoot?: CreateRoot): string | HTMLElement
@returns a div
HTMLElement with the <FavoritePropertyList />
rendered within it.
Parameter | Type | Description |
---|---|---|
propertyData | PropertyData | PropertyData containing Favorite records to display. |
orientation | Orientation | Orientation of the items |
createRoot | CreateRoot | createRoot function imported from import { createRoot } from "react-dom/client"; |
Returns - string | HTMLElement
a div
HTMLElement with the <FavoritePropertyList />
rendered within it.
Defined in
Last Updated: 20 November, 2024
Found something wrong, missing, or unclear on this page?Raise an issue in our repo.