Use-MySQL-JSON-field-in-Laravel

Use MySQL JSON field in Laravel

I have been working on an application which needs to store a lot of metadata about user profile, we discussed with the team about using NoSQL database (MongoDB) since its a JSON data set which can be extended and customized for the specific user profile due to its schemaless structure. As we know from MySQL 5.7.8 JSON field types are supported natively, not only we can store data as JSON but we can run the where clauses on it. So we used this fields type instead of using a full NoSQL DB, Let’s see how we can use it in a Laravel app. Continue reading…

build-a-laravel-roles-and-permissions

Easy roles and permissions in Laravel 5

Laravel comes with Authentication and Authorization out of the box, I have implemented many role and permissions based system in the past, using laravel, it’s peace of cake. In this post, we are going to implement a fully working and extensible roles and permissions on laravel 5. When we finish we will have a starter kit which we can use for our any future project which needs roles and permissions based access control (ACL). Continue reading…

Youtube like app with Vue.js and Laravel

YouTube like app with Vue.js and Laravel

Earlier we have build our API Create REST API with authentication using Laravel Passport for youtube like app to share videos and comment on them, In this part we are going to implement front-end with Vue.js v2 and improve our API. This will give you very good idea on how you can create app with Vue.js Component, Vue Router and Laravel. Since Laravel 5.4 comes with bootstrap out of the box we will use it for UI. Let’s get started by installing Vue router configuring it. Continue reading…

Vue.js directive to submit and server-side validatate forms using AJAX

Vue.js directive to submit and server-side validatate forms using AJAX

Submitting a Form using classical post request will work but it does don’t give the user feedback while it’s submitting and overall not a great user experience. I find myself creating Laravel apps which uses Vue in many places, but if it’s not a complete SPA (without Vue router),  to make forms more interactive I have created a directive v-ajax-submit which I use religiously in my apps to turn boring forms more fun. Continue reading…

REST API with authentication using Laravel Passport

Create REST API with authentication using Laravel Passport

In this post, we are going to dig into REST API building using Laravel 5.4 and Passport OAuth2 server provided by laravel. This is the next part of my post Advance interactive database seeding in Laravel post, we left off at migration and seeding of the database. Let’s build the API which will be consumed by our vue.js front end later. Continue reading…

Subscription-with-coupon-using-Laravel-Cashier-&-Stripe

Subscription with coupon using Laravel Cashier & Stripe

We developer always find our selfs to roll some sort of subscription system for web apps running on SaaS (Software as a service) model, it can be simple as subscription for a music store, for mailing app etc. and everyone is offering some sort of coupon to boost their sale, in order to achieve these functionalities we are going to use Strip and Laravel Cashier which make handling subscription a breeze. Continue reading…

Advance interactive database seeding in Laravel

We all need Database seeding when developing medium to large size application or any API, Laravel comes with Database Seeding capabilities but since Laravel 5.1, framework has introduced the Model Factory which is amazing, you just define your Model default fields values using Faker, which gives you all type of dummy data, I find its lot faster and very easy to use.

Continue reading…