Lessons



Configuring Lucid and our Database Connection
In this lesson, we'll learn how we can configure Lucid to use a different driver other than SQLite; PostgreSQL is shown but MySQL and MSSQL are much the same. Then, we'll set up our connection details so that we can successfully connect to our database.



Let's Learn AdonisJS 6 #2.11
Defining A Structure for our Movie using Models
In this lesson, we'll introduce the concept of models by using one to define the properties our movies should contain. We'll then stub some methods that will mock calls we'll later be able to use to load data from our database.



Model vs Database Query Builder
In this lesson, we'll take a look at the differences between the model and database query builders.




A Deep Dive Into Mixins & Compose
In this lesson, we'll walk through what mixins are and how they work by first inspecting them as plain objects then working our way into classes then finally TypeScript. We'll then implement mixins via AdonisJS' compose utility.



Limiting, Sorting, & Pagination with the Query Builder
In this lesson, we'll take a look at the various options we have to limit results when using the query builder including first, firstOrFail, limit, and pagination. We'll also learn how we can sort our results.



Intro to the Query Builder & It's Where Statements
In this lesson, we'll introduce the query builder. We'll spend most of our time looking at its various where statement options and how we can use them to build queries.


AdonisJS Quick Tip #18.0
How To Use AdonisJS Model Hooks To Log All User Actions
In this lesson, we’ll be taking a look at how we can log any and every user action performed against our AdonisJS models.


Defining Our AdonisJS Filter Form Handler
In this lesson, we'll expand on the filter query we built in the last lesson by reusing the query within a service for our filter form handler.


Creating Our Filter Query with AdonisJS
In this lesson, we'll create the route and query we'll need to get filtered results with our filter form using the Lucid ORM and AdonisJS.


AdonisJS Quick Tip #16.0
Exploring My Favorite AdonisJS Model Query Builder Macros: Tips and Examples
In this lesson, I'll highlight a few of my favorite Model Query Builder Macros that I carry with me from project to project. Have a favorite of your own? Let me know in the comments!


Easy Querying with Static Model Query Methods
In this lesson, we'll learn what static methods are available on our Lucid Models to help us easily query records from our database. These methods offer a convenient query option compared to the query builder.


Password Hashing & Model Hook Overview
In this lesson, we'll learn briefly about the model hooks available and how they work. Then, we'll walk through an example by hashing our password anytime it is changed.


Creating Records with Lucid ORM
In this lesson, we'll learn various ways we can create and bulk-create records using the AdonisJS Lucid ORM.


Defining Model Relationships
In this lesson, we'll learn how to define relationships on our Lucid Models. We'll cover one-to-one, many-to-one, one-to-many, and many-to-many relationship definitions.


Creating Teams & Setting Default Team
In this stream, we'll be adding the ability to create new teams, set the default team for a user when they switch between teams, and auto-forward users to their default team after login.


Database Migrations To Lucid Models
In this lesson, we'll walk through examples of transferring our database migrations into our Lucid Models. This will pave the way for us to begin CRUD operations in later lessons.


Database Schema to Migration
In this lesson, we'll walk through a real-world example of a database schema and how to create migrations. We'll define each table's columns, primary keys, and foreign keys.


What Is A Model?
In this lesson, we'll delve into AdonisJS Models learning what they are, what they represent, how to create them, what we can do with them, and more.
Showing 109 to 126 of 150 results