-
-
Notifications
You must be signed in to change notification settings - Fork 802
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: allow extra args to be passed to nextjs cli #4252
feat: allow extra args to be passed to nextjs cli #4252
Conversation
🦋 Changeset detectedLatest commit: 63dc838 The changes in this PR will be included in the next version bump. This PR includes changesets to release 8 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
const extraArgs = nextArgs["_"].filter((arg) => arg !== "start") | ||
|
||
const config: ServerConfig = { | ||
rootFolder: process.cwd(), | ||
port: nextArgs["--port"], | ||
hostname: nextArgs["--hostname"], | ||
inspect: nextArgs["--inspect"], | ||
env: process.env.NODE_ENV === "production" ? "prod" : "dev", | ||
extraArgs, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hey thank you! Been wanting this for awhile.
Few things
- we need to make sure extraArgs is not also including ones we explicitly use (like
--inspect
) - we should remove our use of
--hostname
and--port
while we are here, they are legacy and no longer needed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hi @julianklumpers, are you able to make these changes?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, sorry for my late reply. Will try to implement this very soon.
Hey, I'm going to close this for now as it's gone cold. Feel free to fix and re-open :) |
Closes: -
What are the changes and their implications?
Allow extra args to be passed to the nextjs CLI. For example in my case:
blitz dev -p 3000 --experimental-https
. The--experimental-https
will be passed down to he nextjs cli.Bug Checklist
pnpm changeset
in the root directory)Feature Checklist
pnpm changeset
in the root directory)main
branch)