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

Make "move line" command to work contextually #84763

Open
aminpaks opened this issue Nov 14, 2019 · 2 comments
Open

Make "move line" command to work contextually #84763

aminpaks opened this issue Nov 14, 2019 · 2 comments
Assignees
Labels
editor-autoindent Editor auto indentation issues feature-request Request for new features or functionality javascript JavaScript support issues typescript Typescript support issues
Milestone

Comments

@aminpaks
Copy link

aminpaks commented Nov 14, 2019

VSCode "move line" command is a fantastic feature. But it would be way more productive if it works with multiline key-values in objects.

For example imagine the following object declaration:

const someObj = {
  isValid: false,
  position: {
    top: 1,
    bottom: 0,
  },
};

if we wanna move position including its value one line higher above isValid(either we have to select multiple lines or) it only moves the position: {.

It would be much more productive and ideal when the cursor is on the position: { line, the "move up" command moves the whole position key including its value (the nested object declaration) all together.

This would be the ideal result moving the position key only by one "move up" command:

const someObj = {
  position: {
    top: 1,
    bottom: 0,
  },
  isValid: false,
};

instead of this:

const someObj = {
  position: {
  isValid: false,
    top: 1,
    bottom: 0,
  },
};

Of course this could be done as an extension but I thought first brainstorm this with the team.

@rebornix rebornix self-assigned this Nov 14, 2019
@rebornix rebornix added the editor-autoindent Editor auto indentation issues label Nov 14, 2019
@rebornix rebornix added the feature-request Request for new features or functionality label Oct 8, 2020
@aiday-mar aiday-mar added javascript JavaScript support issues typescript Typescript support issues labels Mar 15, 2024
@aiday-mar aiday-mar assigned aiday-mar and unassigned rebornix Mar 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
editor-autoindent Editor auto indentation issues feature-request Request for new features or functionality javascript JavaScript support issues typescript Typescript support issues
Projects
None yet
Development

No branches or pull requests

4 participants
@rebornix @aminpaks @aiday-mar and others