Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

feat(nuxi): support --dotenv for dev, build and preview commands #7660

Merged
merged 10 commits into from
Sep 26, 2022

Conversation

cpreston321
Copy link
Contributor

@cpreston321 cpreston321 commented Sep 19, 2022

πŸ”— Linked issue

Issue: nuxt/nuxt#14963

❓ Type of change

  • πŸ“– Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

Wanted to help with stubbing out and adding --dotenv to dev, preview and build but for build I would think this would be an override during build but I could not find and overrides so I left build out for now until I can learn the best way to override it.

  • nuxi dev
    • [Added] [--dotenv] option - relative to rootDir defaults to rootDir
  • nuxi preview
    • [Added] [--dotenv] option - relative to rootDir defaults to rootDir
  • nuxi build
    • [Added] [--dotenv] option - relative to rootDir defaults to rootDir

I will update docs once I have more information!

Thanks πŸ’š

πŸ“ Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@netlify
Copy link

netlify bot commented Sep 19, 2022

βœ… Deploy Preview for nuxt3-docs ready!

Name Link
πŸ”¨ Latest commit 4cbea56
πŸ” Latest deploy log https://app.netlify.com/sites/nuxt3-docs/deploys/6330dafe670184000a421254
😎 Deploy Preview https://deploy-preview-7660--nuxt3-docs.netlify.app
πŸ“± Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@cpreston321 cpreston321 changed the title feat(nuxi): add --dotenv to dev & preview command feat(nuxi): add --dotenv to nuxi dev & nuxi preview Sep 19, 2022
@pi0
Copy link
Member

pi0 commented Sep 20, 2022

Nice work! For build command you can pass dotenv option to the loadNuxt.

@cpreston321 cpreston321 marked this pull request as ready for review September 20, 2022 13:06
@cpreston321 cpreston321 changed the title feat(nuxi): add --dotenv to nuxi dev & nuxi preview feat(nuxi): add --dotenv to nuxi dev, nuxi preview & nuxi build Sep 20, 2022
@cpreston321
Copy link
Contributor Author

@pi0 Thanks for the response! I added it to nuxi build and updated docs accordingly

@cpreston321 cpreston321 changed the title feat(nuxi): add --dotenv to nuxi dev, nuxi preview & nuxi build feat(nuxi): stub --dotenv for nuxi dev, nuxi preview & nuxi build Sep 21, 2022
@pi0 pi0 changed the title feat(nuxi): stub --dotenv for nuxi dev, nuxi preview & nuxi build feat(nuxi): support --dotenv for dev, build and preview commands Sep 26, 2022
Copy link
Member

@pi0 pi0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks <3

@pi0 pi0 merged commit 2e080c2 into nuxt:main Sep 26, 2022
@danielroe danielroe mentioned this pull request Oct 9, 2022
@cpreston321 cpreston321 deleted the feat/nuxi-env-path branch October 19, 2022 14:10
@danielroe danielroe added the 3.x label Jan 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants