Closed
Description
Hi, I wonder if it would be good to have something like this. (maybe it's already achievable via current Vue functional, but I didn't find it)
Imagine I have a 12 rows Grid component that has props of xs, sm,md and lg, has a single slot and
looks like this:
<Grid xs='12' sm='6' lg='3'>
slot content here
</Grid>
What I want is to have something like a modifier for the wrapped components, so it would be possible to do something like this
<ElementsList xs='1' sm='2' lg='3' passToSlot='true'>
<Grid>Content</Grid>
<Grid>Content</Grid>
<Grid>Content</Grid>
</ElementsList>
The ElementsList takes the props, transforms them and passes to Grid accordingly.
So after the component passes props to slot I have something like this:
<ElementsList xs='1' sm='2' lg='3' passToSlot='true'>
<Grid xs='12' sm='6' lg='3'>
slot content here
</Grid>
<Grid xs='12' sm='6' lg='3'>
slot content here
</Grid>
<Grid xs='12' sm='6' lg='3'>
slot content here
</Grid>