A route that encompasses everything not mached above in the hierarchy?

I have this path at the very end, in router.ex:

get("/*path", ErrorController, :not_found)

But it won’t catch:

a) post, put, delete and others

b) json, xml and others

How can I create a path that encompasses everything and what hasn’t matched with any of the routes above?

You can use match instead of get: Phoenix.Router — Phoenix v1.5.9

3 Likes