1
0
Fork 0
mirror of https://github.com/archtechx/laravel-tips.git synced 2025-12-12 21:34:03 +00:00
laravel-tips/content/tips/you-can-pass-variables-to-blade-views-using-the-withfoobar-syntax.md
Samuel Štancl b451d14953 Week 11/2022
2022-03-20 20:41:25 +01:00

11 lines
No EOL
498 B
Markdown

---
title: 'You can pass variables to Blade views using the `withFoo($bar)` syntax '
tweet_id: '1505269888616591363'
thread_slug: weekly-thread-2022-11
author_username: aschmelyun
images:
- 'https://pbs.twimg.com/media/FNweUY-XMAQg4RV.jpg'
created_at: 2022-03-19T19:48:02+00:00
slug: you-can-pass-variables-to-blade-views-using-the-withfoobar-syntax
---
I had no idea that you could pass data into Laravel responses using with{Variable} magic methods! I kind of like this way a little better...