F # Visual Power Tools not working

I am trying to work with F#. For all projects in the solution, VS2015I want to have a similar code style. I installed Visual F # Power Tools and set the formatting configuration to: <img src = "https://i.stack.imgur.com/j4SUF.png" alt = "enter a description of the image here">

According to this configuration (space after comma), the following code:

fun unit ->Log.Information( "Found: {category}\\{name}\\{instance}",category,name,instance )

should be converted to:

fun unit ->Log.Information( "Found: {category}\\{name}\\{instance}", category, name, instance )

But when I try to format the documment by clicking Edit->Advanced->Format Document, nothing happens.

How to format my code?

Update 1

When I try to format the code, I get a message Validation after formatting failed. The original content is preserved.: enter image description here I tried to find this problem and found this problem . Maybe someone is faced with such a problem and knows how to fix it?

+4
source share
1 answer

Try using namespaces. The code below is not formatted:

module Deck
type Color = 
    | Red
    | Green
    | Blue
    | Yellow

However, the following format is formatted correctly

namespace Dummy

    module Deck = 
        type Color = 
            | Red
            | Green
            | Blue
            | Yellow
0
source

Source: https://habr.com/ru/post/1664061/


All Articles