jaredLunde / jaredLunde/masonic
Passing functions as props to the rendered components
- Dominant language
- TypeScript
- Stars
- 1.4k
- Forks
- 63
- PR merge metrics
- No merged PRs in 30d
Description
I was wondering if it is possible to pass functions as props to the rendered components
``
In my case, the Post component needs to take a function in order to execute after certain event. Is it possible to do this? I tried modifying the items array and add the function as an attribute in the object but it didn't work
Contributor guide
Research direction
Start by reviewing the Masonry component's render prop and the item data passed to the rendered Post component. Determine whether function-valued item properties are intended to be supported and define the expected callback behavior, then verify the result with the project's existing tests if applicable.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100