when using feathers express, it gives page not found error #2355

1.1k Views Asked by At

I'm intergrating feathers js both on backend and frontend and I got page not found error when I tried this implementation. I would appreciate your help. thanks for the awesome work!

code https://github.com/react-boilerplate/react-boilerplate/issues/2355

1

There are 1 best solutions below

0
On

This is the same problem discussed in this FAQ.

Just like in Express itself, the order of middleware matters. If you registered a custom middleware outside of the generator, you have to make sure that it runs before the notFound() error midlleware.

This means that

app.use(express.notFound());

Always has to be the last app.use call.