Got it! Your answer helped me to track down the code block I was looking for: Mojo::Template::_wrap() <https://github.com/mojolicious/mojo/blob/master/lib/Mojo/Template.pm#L259>.
I was just curious how it works. Thank you! On Fri, Oct 4, 2019 at 2:10 PM Dan Book <gri...@gmail.com> wrote: > Mojolicious::Plugin::EPRenderer passes the stash as args to > Mojo::Template, which has the vars option enabled and thus creates > variables based on the passed hash. > > -Dan > > On Fri, Oct 4, 2019 at 1:33 PM Stefan Adams <s1037...@gmail.com> wrote: > >> In Mojolicious::Guides::Render#Embedded-Perl >> <https://mojolicious.org/perldoc/Mojolicious/Guides/Rendering#Embedded-Perl>, >> it says: >> >> At the beginning of the template, stash values that don't have invalid >> characters in their name get automatically initialized as normal variables, >> and the controller object as both $self and $c. >> >> >> How are stash values initialized as normal variables? That is, what code >> is responsible for making this happen? >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Mojolicious" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to mojolicious+unsubscr...@googlegroups.com. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/mojolicious/CACyQ%2BFSdKdJ15sPUTv19N3U7wc81O%3D7hv4i-kk%2BJ%3D_9Q%2BUd7Cw%40mail.gmail.com >> <https://groups.google.com/d/msgid/mojolicious/CACyQ%2BFSdKdJ15sPUTv19N3U7wc81O%3D7hv4i-kk%2BJ%3D_9Q%2BUd7Cw%40mail.gmail.com?utm_medium=email&utm_source=footer> >> . >> > -- > You received this message because you are subscribed to the Google Groups > "Mojolicious" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to mojolicious+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/mojolicious/CABMkAVWt%3DQhwzi-iDc7dQxxVf0whvWnG8_7bZpVEJC8om%3DSFCQ%40mail.gmail.com > <https://groups.google.com/d/msgid/mojolicious/CABMkAVWt%3DQhwzi-iDc7dQxxVf0whvWnG8_7bZpVEJC8om%3DSFCQ%40mail.gmail.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "Mojolicious" group. To unsubscribe from this group and stop receiving emails from it, send an email to mojolicious+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/mojolicious/CACyQ%2BFTfjnSXNw9mqK3SDfU%3D2a5QMLJMs%2BnJgvLoSOXuCjAPxA%40mail.gmail.com.