Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

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

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

like image 591
Seunghun Sunmoon Lee Avatar asked Jan 01 '26 21:01

Seunghun Sunmoon Lee


1 Answers

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.

like image 79
Daff Avatar answered Jan 03 '26 12:01

Daff



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!