Buy your loved one the ultimate gift. Lifetime gift certificates are $100 off.

Back to the Learning!

Laracasts is packed full with over 1,000 lessons just like this one.

Sign up to get full access or log in to your account and sit back.

Published On May. 11th 2017

Let's Build A Forum with Laravel and TDD: A New Reply Component

Episode 37 Run Time 11:44

Download

Now that we're thinking in terms of Vue collections, we can easily turn the form for publishing a new reply into its own component. This way, when the user submits the form, we can simply perform an AJAX call to persist the data, and then push to the "replies" collection - which will, in response, automatically trigger a re-render.

View the source code for this episode on GitHub.