From [How to create a jQuery plugin with methods?](https://stackoverflow.com/questions/1117086/how-to-create-a-jquery-plugin-with-methods)

How to do the same thing in javascript **Without JQuery**

**JQuery**

```
    (function ( $ ) {

    $.fn.greenify = function() {
        this.css( "color", "green" );
        return this;
    };

}( jQuery ));

```

**Js**

```
?

```