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

x/playground: consider alternative keyboard shortcut for "Run this code" #58892

Open
Deleplace opened this issue Mar 6, 2023 · 1 comment
Open
Labels
NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone

Comments

@Deleplace
Copy link
Contributor

Deleplace commented Mar 6, 2023

What version of Go are you using (go version)?

go1.20.1

(in the playground actually, not my computer)

Popular playgrounds' key bindings for "Run"

Playground   macOS Linux Windows
Go https://go.dev/play/ Shift-Enter Shift-Enter Shift-Enter
Rust https://play.rust-lang.org/ Cmd-Enter OR Ctrl-Enter Ctrl-Enter Ctrl-Enter
Dart https://dartpad.dev/ Cmd-Enter OR Ctrl-Enter Ctrl-Enter Ctrl-Enter
Kotlin https://play.kotlinlang.org/ Ctrl-R Ctrl-F9 Ctrl-F9
Sharplab https://sharplab.io/ autoplay autoplay  autoplay
Wandbox https://wandbox.org/ Ctrl-Enter Ctrl-Enter Ctrl-Enter
Colab https://colab.google/ Cmd-Enter OR Ctrl-Enter Ctrl-Enter Ctrl-Enter
BigQuery https://console.cloud.google.com/bigquery Cmd-Enter Ctrl-Enter Ctrl-Enter

In general

It would be nice to reach convergence among different playgrounds for this specific standard feature, for the same reasons that it's nice to have (often) the same shortcut for Copy & Paste

Suggestion for Go's playground

Add Ctrl-Enter (Linux, Windows) / Cmd-Enter (macOS) as bindings for "Run this code".

This seems to be more widespread and more intuitive than the current binding Shift-Enter.

This can be done while keeping the existing binding Shift-Enter.

This does conflict on Linux with the current binding for "Format this code", so we'd need to decide if changing things for "Format this code" is acceptable damage.

@gopherbot gopherbot added this to the Unreleased milestone Mar 6, 2023
@cagedmantis cagedmantis added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Mar 6, 2023
@cagedmantis cagedmantis changed the title x/playground: Consider alternative keyboard shortcut for "Run this code" x/playground: consider alternative keyboard shortcut for "Run this code" Mar 6, 2023
@cagedmantis
Copy link
Contributor

/cc @toothrot @findleyr

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Projects
None yet
Development

No branches or pull requests

3 participants