Skip to content

Commit

Permalink
Merge branch 'example/custom-routes-proxying' of github.com:ijjk/next…
Browse files Browse the repository at this point in the history
….js into example/custom-routes-proxying

# Conflicts:
#	examples/custom-routes-proxying/package.json
  • Loading branch information
ijjk committed Jun 20, 2020
2 parents dc93a1e + 98d1dc5 commit 5cbc772
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/custom-routes-proxying/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Custom Routes Proxying Example

This example shows the most basic example using Next.js' new custom routes feature to proxy requests to an upstream server. We have 3 pages: `pages/index.js`, `pages/about.js`, and `pages/hello/[slug].js`. All of these pages will be matched against before requests are proxied to the upstream server.
This example shows the most basic example using Next.js' new custom routes feature to proxy requests to an upstream server. We have 3 pages: `pages/index.js`, `pages/about.js`, and `pages/hello/[slug].js`. All of these pages will be matched against Next.js and any other path will be proxied to the upstream server.

This approach is very helpful when you are trying to incrementally migrate your application to Next.js but still need to fallback to an existing application. You can add pages to your Next.js application one-by-one and then for non-migrated pages Next.js can proxy to the existing application until they are able to be migrated.

Expand Down

0 comments on commit 5cbc772

Please sign in to comment.