Skip to content
This repository was archived by the owner on Jan 28, 2025. It is now read-only.

Conversation

@jlaramie
Copy link
Contributor

Describe the bug

To keep the folder structure a bit cleaner I keep the nextjs code in a subdirectory. In order to do this you configure next.config.js distDir: ../back/../to/../root/.next and you call next build path/to/pages

The Problem

  • The current build function for does not allow you to add arguments to the build function.
  • The current build function assumes your staticPath is the same as nextConfigDir

Solution

  • Expose a new input nextBuildArguments for passing additional info into the nextjs build.
  • Expose a new input staticPath which combines with nextConfigDir and allows you to override the location of the static assets.

…h custom folder structures and builds

- Updated the readme
@danielcondemarin
Copy link
Contributor

@jlaramie Thank you for PR-ing. Hope you had open an issue first. I've submitted a new Feature Request which is how I want to move forward to solve issues like this: #214.

@jlaramie
Copy link
Contributor Author

@danielcondemarin Yeah this was something I needed so I forked to get it. I appreciate you looking over this issue and coming up with another solution. Should I go ahead and close this pull request then?

@danielcondemarin
Copy link
Contributor

danielcondemarin commented Oct 22, 2019

Yes lets close it. If you have the time Im happy to take a PR for the decoupled build 🙂

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants