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 () {
}

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.0.3
    1
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.0.3
    1
  • 0.0.2
    0

Package Sidebar

Install

npm i classgen

Weekly Downloads

1

Version

0.0.3

License

MIT

Last publish

Collaborators

  • yaniv
  • kessler