What Naming Convention you use for properties ?

Hi,
I am a bit manic when I code and I’m stuck when I want write properties.

Should I follow Official Naming Convention (on MSDN) and UpperCamelCased properties ?

Or since Unity expose his API thought lowerCamelCased properties, should I do the same because I work with Unity (on docs) ?

You, what Naming Convention have you choose to follow when you writing properties ?

Here is what I usually do:

private var myProperty:String = "A Property";
public function myFunction(){
    var my_local_var:String = "Local Variable";
}

Not quite the same thing. He’s speaking specifically about properties. I use the MSDN suggested standard.

public class Foo
{
    public string Bar { get; set; }
}

Uppercase please

I use uppercase, this also gives a certain uniqueness to the unity properties. easy to distinguish what’s my code and what’s unity

Ok, thanks to all !
UpperCamelCase seems most widely used, this is what I thought.
When you think, that’s logic, Unity doesn’t have a clearly defined Naming Convention, unlike C#.

Properties are meant to look like fields, so I just use the same naming convention for both. That said, naming private properties with _underscoredLowerCamelCase feels odd. Still, private properties are rare.

I use the Resharper naming convention which is UpperCamelCase for public / internal / protected and _lowerCameCase for private and I do this on fields as well as properties as they are meant to be the ‘same’ to the outside

UpperCamelCase for properties. I’ve formed the habit from software dev in c#. It also just feels nice :smile: