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: add CLI keyboard shortcuts #6014

Closed
wants to merge 3 commits into from

Conversation

aleclarson
Copy link
Member

@aleclarson aleclarson commented Dec 8, 2021

Description

This is a continuation of #3182 with the following changes:

  • Rebased onto main branch
  • Add bindShortcuts method to ViteDevServer
  • Added h shortcut for toggling HMR updates (useful when debugging)

⚠️ Do not squash!


What is the purpose of this pull request?

  • Bug fix
  • New Feature
  • Documentation update
  • Other

@aleclarson aleclarson added the p2-nice-to-have Not breaking anything but nice to have (priority) label Dec 8, 2021
aleclarson and others added 2 commits December 8, 2021 16:27
The shortcuts include:

  - [r] Restart the server (useful for third party config changes)
  - [o] Open the project in your default browser
  - [f] Clear the cache for optimized dependencies (then restart the
    server)

Co-authored-by: HomyeeKing <[email protected]>
Press "h" to toggle HMR updates on/off.

Useful when you hit a bug and don't want your code edits to refresh the browser (which would mean losing the error logs and app state).
@joelmukuthu
Copy link

Hi @aleclarson, is this still on your radar?

@aleclarson
Copy link
Member Author

@joelmukuthu I'm using it in a fork without issue. Would you like to rebase this and open a new PR?

@joelmukuthu
Copy link

@aleclarson Cool, I'll look into it this weekend.

@joelmukuthu
Copy link

@aleclarson done via #9673. If you'd prefer, I can close that PR and create one targetting your feat/shortcuts instead so your PR here is updated. Just let me know!

@aleclarson aleclarson closed this Aug 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
p2-nice-to-have Not breaking anything but nice to have (priority)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants