1.3.5 â€ĸ Published 10 months ago

next-action-router v1.3.5

Weekly downloads
-
License
ISC
Repository
github
Last release
10 months ago

For documentation head over to https://next-action-router.netlify.app

A little background

I've had experience building with Strapi and Express.js, and what I really loved about both projects is their routing and middleware systems.

These patterns offer several benefits, including:

  • Enhanced code readability
  • Increased modularity
  • Cleaner API syntax
  • More robust implementations
  • Maximum code reusability

With the introduction of server actions in Next.js, writing APIs has become much easier. However, the advanced routing and middleware patterns I valued in Strapi and Express.js are still not natively supported by Next.js.

A few months ago, when I started building a full-stack e-commerce website, I quickly realized the need for these abstractions. Unfortunately, I couldn't find any simple and useful solutions. So, I created a bare minimum implementation of this library for my project. Drawing on the lessons and ideas from that draft implementation, I developed this library with more advanced, type-safe features.

I've got more ideas but for now let's get started!

Aim

This library aims to simplify working with nextjs server actions. One can easily compose complex server actions using the provided abstractions.

Features

  • 🔀 Action Routing
  • âš™ī¸ Input Validation
  • đŸĒļ Light weight
  • đŸ—’ī¸ Logging
  • â›“ī¸ Middleware Chaining
  • đŸ”Ĩ Robust error handling
  • ⚡ Snappy DX
  • 🇹 Type Safety
1.3.5

10 months ago

1.3.4

10 months ago

1.3.3

10 months ago

1.3.2

10 months ago

1.3.1

11 months ago

1.3.0

11 months ago

1.2.9

11 months ago

1.2.8

11 months ago

1.2.7

11 months ago

1.2.6

11 months ago

1.2.5

11 months ago

1.2.4

11 months ago

1.2.3

11 months ago

1.2.2

11 months ago

1.2.1

11 months ago

1.2.0

11 months ago