.net - Custom Naming Style Options in Resharper For Backing Fields -


the coding standard in organization private fields lowercamelcase backing fields used properties prefixed underscore (_). there way add rule backing fields in resharper naming style tool.

here's naming rule editor: resharper

i'd rather error not show local variables rename

examples in vb , c#:

vb:

public class employee      'should lowercamelcase     private usecode string = "new"      'should _lowercamelcase     private _name string      public property name() string                     return _name         end         set(byval value string)             _name = value         end set     end property  end class 

c#:

public class employee {      //should lowercamelcase     private string usecode = "new";      //should _lowercamelcase     private string _name;      public string name {         { return _name; }         set { _name = value; }     }  } 

whether agree or not naming convention, there way ask reshaper enforce this?

there no way enforce naming rules backing fields in resharper, can add multiple rules entity kind.

enter image description here

with settings applied, resharper allow have fields , without underscore prefix.


Comments

Popular posts from this blog

ios - UICollectionView Self Sizing Cells with Auto Layout -

node.js - ldapjs - write after end error -

DOM Manipulation in Wordpress (and elsewhere) using php -