From 0331b048b349d28ea9aa1887abf1abaac324bf7c Mon Sep 17 00:00:00 2001 From: Z4NR34L Date: Fri, 12 Jul 2024 09:44:29 +0200 Subject: [PATCH] feat: fine-tuning docs content --- apps/docs/content/docs/examples/next-auth.mdx | 2 +- apps/docs/content/docs/index.mdx | 4 +++- apps/docs/content/docs/matchers/simple.mdx | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/apps/docs/content/docs/examples/next-auth.mdx b/apps/docs/content/docs/examples/next-auth.mdx index a752223..4f1ad05 100644 --- a/apps/docs/content/docs/examples/next-auth.mdx +++ b/apps/docs/content/docs/examples/next-auth.mdx @@ -11,7 +11,7 @@ Do to so, please follow the [Getting Started](https://authjs.dev/getting-started Here you will find example middleware configuration for Next-Auth package to restrict access to `/page2` route. -```typescript {3,13} +```typescript {3,13} title="middleware.ts" import createMiddleware from 'next-easy-middlewares'; import { type NextRequest, NextResponse } from 'next/server'; import { auth } from '@/auth'; diff --git a/apps/docs/content/docs/index.mdx b/apps/docs/content/docs/index.mdx index 115d7c6..e049659 100644 --- a/apps/docs/content/docs/index.mdx +++ b/apps/docs/content/docs/index.mdx @@ -3,6 +3,8 @@ title: Getting Started description: Getting started with Next Easy Middlewares --- + + import {Tab, Tabs} from 'next-docs-ui/components/tabs'; ## Motivation @@ -40,7 +42,7 @@ Paste installation command into your terminal to install package. ## Basic usage -```typescript title="/middleware.ts" {5,9} +```typescript title="middleware.ts" {1, 5,9} import { createMiddleware } from 'next-easy-middlewares'; import { type NextRequest, NextResponse } from 'next/server'; diff --git a/apps/docs/content/docs/matchers/simple.mdx b/apps/docs/content/docs/matchers/simple.mdx index 21c83ed..7aeed6a 100644 --- a/apps/docs/content/docs/matchers/simple.mdx +++ b/apps/docs/content/docs/matchers/simple.mdx @@ -3,7 +3,7 @@ title: Simple matcher description: Simple matcher type and how to use it. --- -```typescript +```typescript title="middleware.ts" // ... const middlewares = {