symfony / webpack-encore-bundle

Symfony integration with Webpack Encore!
https://symfony.com/webpack-encore
MIT License
933 stars 83 forks source link

Add Twig function and filter for Stimulus Outlets integration #205

Closed pbories closed 1 year ago

pbories commented 1 year ago

Hello there,

The Outlets API was introduced in Stimulus v3.2.0.

It would be great to have a Twig function to generate the data attribute data-[identifier]-[outlet-name]-outlet="[selector]" in the templates, just like stimulus_controller, stimulus_action and stimulus_target functions.

Should I try to make a PR or is someone already working on this ?

pbories commented 1 year ago

I opened a PR : https://github.com/symfony/webpack-encore-bundle/pull/206

WDYT ?

weaverryan commented 1 year ago

Outlets added to StimulusBundle! Use the functions from that bundle instead.

Cheers!