Skip to content
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(vite): add a preview-server executor for Vite #14326

Merged
merged 1 commit into from
Jan 13, 2023

Conversation

vicb
Copy link
Contributor

@vicb vicb commented Jan 12, 2023

Adds a preview-server executor to the Vite plugin to ebable vite preview mode.

This is the first required step for #14125

Next step will be to update the generators.

You can test it by adding a target to your project.json:

    "preview": {
      "executor": "@nrwl/vite:preview-server",
      "options": {
        "buildTarget": "my-app:build:development",
        "host": "localhost",
        "port": 4300
      },
      "configurations": {
        "production": {
          "buildTarget": "my-app:build:production"
        }
      }
    },

and running nx preview my-app.

Thanks @mandarini for your help along the process!

@vercel
Copy link

vercel bot commented Jan 12, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
nx-dev ✅ Ready (Inspect) Visit Preview Jan 12, 2023 at 10:41PM (UTC)

@nx-cloud
Copy link

nx-cloud bot commented Jan 12, 2023

☁️ Nx Cloud Report

CI is running/has finished running commands for commit 277b138. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch


⌛ The following target is in progress

✅ Successfully ran 9 targets

Sent with 💌 from NxCloud.

Copy link
Member

@mandarini mandarini left a comment

Choose a reason for hiding this comment

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

Looks good from a first glance. I will make sure to try it out locally, too. Thank you @vicb !

@mandarini
Copy link
Member

mandarini commented Jan 13, 2023

Will merge in the next hour. Let's see if we need to add any different or additional properties for the executor!

@mandarini mandarini merged commit c94ac41 into nrwl:master Jan 13, 2023
@vicb
Copy link
Contributor Author

vicb commented Jan 13, 2023

Thanks!

@github-actions
Copy link

This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 11, 2023
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