Line break inside HTML tags in Visual Studio Code

2

How do I enable line wrapping within HTML tags to stay that way?

<input 
      class="someClass"
      id="someId"
      name="someName"
      ng-model="vm.model"
      ng-click="vm.someAction()"/>

When formatting text in Visual Code (Alt + Shift + F) it leaves HTML tags like this:

<input class="someClass" id="someId" name="someName" value="someValue" ng-model="vm.model" ng-click="vm.someAction"/>

It removes all line breaks I've inserted. In NetBeans I do not have this problem. I have already changed the Code settings, downloaded extensions and nothing works.

    
asked by anonymous 10.12.2016 / 02:33

1 answer

1

Good morning,

First of all I would like to point out that this feature is really missing in the visual code, and if it has already been found, it is not in the shortcuts.

But to enable the breaking of lines on the same hand you go in "Files> Preferences & Settings" then in the "Editor" module. You search for "editor.wordWrap" that will be - > : "off" simply change to: "on". This change will automatically perform line breaks.

    
23.05.2017 / 07:21