rsnext/packages/next/lib
Jan Potoms 9da99bcb66
Prepare custom routes loading for adding additional routes (#13857)
Extracted from https://github.com/vercel/next.js/pull/13333, the same exact code lives in that PR as well, but we can merge this separately if it makes reviewing https://github.com/vercel/next.js/pull/13333 easier

This PR does 3 things 
- deduplicate code from build and next-dev-server that loads custom routes from next.config.js  (`loadCustomRoutes`)
- in `loadCustomRoutes`, load these rewrites, headers and redirects configs concurrently instead of sequentially.
- in next-server, make `this.customRoutes` always defined, this allows us to remove the big `if` around its initialization code in `generateRoutes`, which in turn makes it possible to reuse this code for other routing than user defined routes, which is how https://github.com/vercel/next.js/pull/13333 adds its redirects.
2020-06-09 20:16:23 +00:00
..
typescript Added no-shadow rule to eslint (#13645) 2020-06-01 21:00:22 +00:00
coalesced-function.ts Upgrade to Prettier 2 (#13061) 2020-05-18 15:24:37 -04:00
constants.ts Fix message on getStaticPaths conflict with getServerSideProps (#13874) 2020-06-08 10:25:37 -04:00
file-exists.ts Use fs.promises instead of promisify (#12026) 2020-05-02 00:10:19 -04:00
find-config.ts find-up 2020-03-30 16:26:25 -04:00
find-pages-dir.ts Add initial support for new env handling (#10525) 2020-03-26 13:32:41 +01:00
is-serializable-props.ts Added no-shadow rule to eslint (#13645) 2020-06-01 21:00:22 +00:00
load-custom-routes.ts Prepare custom routes loading for adding additional routes (#13857) 2020-06-09 20:16:23 +00:00
load-env-config.ts Added no-shadow rule to eslint (#13645) 2020-06-01 21:00:22 +00:00
oxford-comma-list.ts refactor(typescript): extract preflight functions (#13510) 2020-05-28 23:39:46 +00:00
pretty-bytes.ts Move syntax formatting to prettier (#7454) 2019-05-29 13:57:26 +02:00
recursive-copy.ts chore(next): export/lib/next-server missing types (#13320) 2020-05-24 22:44:05 +00:00
recursive-delete.ts Upgrade to Prettier 2 (#13061) 2020-05-18 15:24:37 -04:00
recursive-readdir.ts Use fs.promises instead of promisify (#12026) 2020-05-02 00:10:19 -04:00
resolve-request.ts Added no-shadow rule to eslint (#13645) 2020-06-01 21:00:22 +00:00
verifyTypeScriptSetup.ts Replace fork-ts-checker-webpack-plugin with faster alternative (#13529) 2020-05-29 08:16:22 +00:00