From 8ca691693f9972096196b2b15b49b2ca2dfbb639 Mon Sep 17 00:00:00 2001 From: Jarred Sumner <709451+Jarred-Sumner@users.noreply.github.com> Date: Tue, 19 Sep 2023 04:32:45 -0700 Subject: Delete extremely out of date docs --- docs/dev/nextjs.md | 33 --------------------------------- 1 file changed, 33 deletions(-) delete mode 100644 docs/dev/nextjs.md (limited to 'docs/dev/nextjs.md') diff --git a/docs/dev/nextjs.md b/docs/dev/nextjs.md deleted file mode 100644 index 92849c989..000000000 --- a/docs/dev/nextjs.md +++ /dev/null @@ -1,33 +0,0 @@ -To create a new Next.js app with bun: - -```bash -$ bun create next ./app -$ cd app -$ bun dev # start dev server -``` - -To use an existing Next.js app with bun: - -```bash -$ bun add bun-framework-next -$ echo "framework = 'next'" > bunfig.toml -$ bun bun # bundle dependencies -$ bun dev # start dev server -``` - -Many of Next.js’ features are supported, but not all. - -Here’s what doesn’t work yet: - -- `getStaticPaths` -- same-origin `fetch` inside of `getStaticProps` or `getServerSideProps` -- locales, zones, `assetPrefix` (workaround: change `--origin \"http://localhost:3000/assetPrefixInhere\"`) -- `next/image` is polyfilled to a regular `` tag. -- `proxy` and anything else in `next.config.js` -- API routes, middleware (middleware is easier to support, though! Similar SSR API) -- styled-jsx (technically not Next.js, but often used with it) -- React Server Components - -When using Next.js, Bun automatically reads configuration from `.env.local`, `.env.development` and `.env` (in that order). `process.env.NEXT_PUBLIC_` and `process.env.NEXT_` automatically are replaced via `--define`. - -Currently, any time you import new dependencies from `node_modules`, you will need to re-run `bun bun --use next`. This will eventually be automatic. -- cgit v1.2.3