Vue Blog Posts

vue javascript
Jul 16, 2022
When to use ref vs reactive in Vue

The release of Vue 3 introduced two new ways of adding reactivity to data in your components, ref and reactive. There's been a bit of confusion surrounding which one's better, or when either should be used. I'm here to hopefully shed some light on their differences, and show how I use them in my applications.

Read more →

vue javascript
Aug 26, 2021
Why you should be using Vue's new Composition API

You keep hearing about this composition API in Vue. But it's a little scary and intimidating, and why it's so much better isn't really all that clear to you. In this article you'll see exactly why you should learn to use it by comparing the old way to the new way. The examples also start out simple and get more complex, so you can see that the composition API isn't really all that different from what you're used to.

Read more →

laravel vue
May 11, 2020
Authenticating a Vue SPA is easy with Laravel Sanctum

Released earlier this year, Laravel Sanctum (formerly Laravel Airlock) is a lightweight package to help make authentication in single-page or native mobile applications as easy as possible. Where before you had to choose between using the web middleware with sessions or an external package like Tymon's jwt-auth, you can now use Sanctum to accomplish both stateful and token-based authentication.

Read more →

laravel vue
Sep 21, 2019
Four ways to pass data from Laravel to Vue

I’ve been working on projects that use both Vue and Laravel for the last two to three years, and during the start of each’s development I have to ask myself “How am I going to pass my data from Laravel to Vue?”. This applies to both applications where the Vue frontend components are tightly coupled to Blade templates, as well as single-page applications running completely separate of the Laravel backend.

Read more →

laravel vue
Jul 21, 2019
Adding real-time updates to your Laravel and Vue apps with laravel-websockets

Earlier this month I launched listpal.co, a to-do app that included websockets functionality so that each user with the list open would see updates from everyone else. It was definitely a learning experience and my first time really diving into the world of Vue + websockets combined. With the help of the laravel-websockets package, it’s super easy to get a websockets server started in a new (or existing) Laravel application.

Read more →