Skip to Main Content
Hands-on Nuxt.js Web Development
book

Hands-on Nuxt.js Web Development

by Lau Tiam Kok Kok Lau
August 2020
Beginner to intermediate content levelBeginner to intermediate
698 pages
12h 2m
English
Packt Publishing
Content preview from Hands-on Nuxt.js Web Development
Writing Route Middlewares and Server Middlewares

Remember when you created a middleware on the server side using Koa in Chapter 8, Adding a Server-Side Framework? Middlewares are both useful and powerful, as you will have noted in cascading with Koa apps, where you can predict and control the flow of your entire app sequentially. So, what about in Nuxt? Well, there are two types of middleware we should explore in Nuxt: route middleware and server middleware. In this chapter, you will learn how to differentiate between them and create some basic middlewares before moving on to the next chapter on authentication, where middlewares are very much needed. We will also use middlewares in the chapters after the next one. So, in this chapter, just ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Test-Driven JavaScript Development

Test-Driven JavaScript Development

Ravi Kumar Gupta
Front-End Development Projects with Vue.js

Front-End Development Projects with Vue.js

Raymond Camden, Hugo Di Francesco, Clifford Gurney, Philip Kirkbride, Maya Shavin

Publisher Resources

ISBN: 9781789952698Supplemental Content