OOJS
Sublime Text Plugin to generate Get/Set methods
Labels language syntax
Details
Installs
- Total 299
- Win 203
- Mac 50
- Linux 46
Jul 27 | Jul 26 | Jul 25 | Jul 24 | Jul 23 | Jul 22 | Jul 21 | Jul 20 | Jul 19 | Jul 18 | Jul 17 | Jul 16 | Jul 15 | Jul 14 | Jul 13 | Jul 12 | Jul 11 | Jul 10 | Jul 9 | Jul 8 | Jul 7 | Jul 6 | Jul 5 | Jul 4 | Jul 3 | Jul 2 | Jul 1 | Jun 30 | Jun 29 | Jun 28 | Jun 27 | Jun 26 | Jun 25 | Jun 24 | Jun 23 | Jun 22 | Jun 21 | Jun 20 | Jun 19 | Jun 18 | Jun 17 | Jun 16 | Jun 15 | Jun 14 | Jun 13 | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Windows | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Mac | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Linux | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 |
Readme
- Source
- raw.githubusercontent.com
OOJS - Sublime Text plugin
Sublime Text Plugin to generate Get/Set methods
OOJS helps developers to generate Getters and Setters in Object Oriented JavaScript fashion. This plugin is an enhanced version of existing proto snippet.
Install
Install OOJS
with Package Control and restart Sublime.
Getting started
Example
# example.js
var exampleNode = function(){
this.prop1;
this.prop2;
this.prop3;
};
/*In this case, the generated code will look like the following*/
exampleNode.prototype.getProp1 = function(){
return this.prop1;
};
exampleNode.prototype.setProp1(prop1){
this.prop1 = prop1;
};
Tips
Keyboard Shortcuts
ctrl+alt+z will generate the getter and setter for all selected properties.
ctrl+alt+g will generate the getter for all selected properties.
ctrl+alt+s will generate the setter for all selected properties.
Access using Menubar
Select the required properties and then choose
- Edit -> OOJS -> OOGS (Getter + Setter)
- Edit -> OOJS -> OOG (Getter)
- Edit -> OOJS -> OOS (Setter)
Access using Context Menu
Select the required properties and then right click and choose
- OO Getter Setter
- OO Getter
- OO Setter
Access using Sidebar Menu
Select the required properties and then right click on the filename in the sidebar and choose
- OO Getter Setter
- OO Getter
- OO Setter
License
MIT License • © Avinash Jayakumar