I need to write a few extension methods in JS. I know just how to do this in C#. Example:
public static string SayHi(this Object name)
{
return Hi + name + !;
}
and then called by:
string firstName = Bob;
string hi = firstName.SayHi();
How would I do something like this in JavaScript?