Command Suggestions in VSCode

4

I am programming in react-native using the Visual Studio Code, in the extensions I installed

  • ESLint
  • JavaScript (ES6) code snippets
  • jsx
  • React Native tools
  • React-Native / React / Redux snippets for es6 / es7
  • Reactjs code snippets

But none of them did what I want, which is to give suggestions for commands such as font styles, font color, background color, and the main options for that kind of thing.

Type transform into an ide yourself

    
asked by anonymous 24.08.2017 / 21:55

3 answers

3

You can also create your own snippets

Go to File > Preferences > User Snippets at the prompt that opens you choose JavaScript for example and creates your binds.

Lookattheexamplebelow:(inthiscase"bgc" is the shortcut for entering the text)

"Cor do Background": {
    "prefix": "bgc",
    "body": [
        "backgroundColor"
    ],
    "description": "colocar cor no background"
}

Another example:

"Estilo de fontWeight": {
    "prefix": "ftw",
    "body": [
        "fontWeight"
    ],
    "description": "colocar estilo de Font Weight"
}

In the template above the "ftw" shortcut fires the text fontWeight complete.

  

You can even create snippets for entire templates, after one read in the official documentation

link

    
26.12.2017 / 11:51
2

There is a plugin that makes your VSCode use the same shortcut keys as Eclipse, it can be a solution. The name of the plugin is: Eclipse Keymap.

    
25.08.2017 / 05:44
1

To autocomplete parameters and values in CSS you can use the IntelliSense for CSS Class Names extension that provides autocomplete for the CSS class name for the HTML class attribute based on the CSS files in your workspace, and also supports the className attribute of React (which may also solve your problem).

    
26.12.2017 / 05:00