#6 Multitenancy in Laravel, authentication in Vue with Sanctum, and more

Welcome to the 6th Andy's Web Dev Tips newsletter! Here's a few things from this week:

Mohamed Said’s Multitenancy in Laravel series

Mohamed is a developer on the core Laravel framework, and has recently started up a YouTube channel where he presents useful and deep-dive tutorials on various questions he’s received about Laravel. One of the ones that kept coming up regularly was how to structure a single app for multiple tenants.

What might that structure look like? Should we use one database or multiple? What about session and app configurations? All of these questions and more are answered in this three-part (so far) video series. You can check out the first video here, which outlines a lot of the above right out of the gate.

Authentication in Vue using Laravel Sanctum

If you haven’t seen it, I released a new video this week detailing how to get started with Laravel’s Sanctum package. It’s a featherweight bundle that lets you easily add an authentication layer to mobile apps, single-page applications, or any external services. In the 23 minute video, I show you how to get started authenticating a user into a Vue SPA and automatically retrieve user details through API requests.

State management in Vue without Vuex

Vuex is a powerful, and deceptively complex package that’s perfect for handling the data stores of a large and spread-out Vue application. However, if you have something that’s on the smaller side, or are being conscious about your app’s data footprint, rolling your own might be worth it. Check out this article by Michael Thiessen for an in-depth tutorial on how to manage a central state in Vue without Vuex.

Creating a desktop application with Laravel and Electron

If you use a desktop application that also has a web-based counterpart, chances are that it’s built using the Electron JS framework. Some of the more popular apps using it include Slack, Discord, and VS Code, but creating your own cross-platform app with it is a fairly straightforward process (especially if you already have a web app that exists). In this short article, Harun over at LaravelArticle.com shows you how to build and package up your own Electron desktop app using Laravel.

That’s it for this week! If you have any questions about the above, or have something you’d like me to check out, please feel free to let me know on Twitter.