These are alternative packages/frameworks in NodeJS that cover some of the primary features in Laravel. This is by no means a comprehensive list of Laravel features (or a comprehensive list of NodeJS alternatives).
Depending on your perspective, this list either shows how it's possible to switch from Laravel to NodeJS or shows why you'd want to stay with Laravel 😃
Full stack framework alternatives: Nest, Adonis
Package alternatives:
Laravel (or Symfony) Feature | NodeJS Alternative |
---|---|
Request routing/handling | express, koa |
Authentication | passport, bcrypt, bcryptjs |
Configuration | dotenv, node-convict |
Dependency injection | Do I need dependency injection in NodeJS? (Stack Overflow) |
ORM | TypeORM, Sequelize, Objection |
DB migrations | (Simple migrations can be run automatically with Sequelize or Objection) Sequelize CLI, graphql-migrate, knex |
Collections | ES functions, lodash |
Logging | winston, debug |
Queues | Redis-based: Bee Queue, kue Other: better-queue, node-rethinkdb-job-queue |
Caching | node-cache |
Blade (HTML templating) | nunjucks, hbs, etc. |
nodemailer | |
Unit tests | mocha + chai |
Dusk (browser tests) | puppeteer |
Artisan commands | Inquirer for interactive commands |
Task scheduling | cron |
Input validation | graphql-constraint-directive (example) |
GraphQL: Lighthouse, laravel-graphql | Apollo Server, graphql-yoga objection-graphql |