classgen

0.0.3 • Public • Published

classgen

generate prototype classes from json arrays

install

$ npm install -g classgen

usage

$ echo '[ "bar" ]' | classgen

prints:

function Foo() {
}

Foo.prototype.bar = function () {
}

replace class name:

$ echo '[ "bar", "foo" ]' | classgen --class=Bleep

prints:

function Bleep() {
}

Bleep.prototype.bleep = function () {
}

Bleep.prototype.bar = function () {
}

Readme

Keywords

Package Sidebar

Install

npm i classgen

Weekly Downloads

0

Version

0.0.3

License

MIT

Last publish

Collaborators

  • yaniv
  • kessler