{"_id":"@0bdx/gen-class","_rev":"1-cc892d1854b08c0c0c524b7e29fd08d3","name":"@0bdx/gen-class","dist-tags":{"latest":"0.0.2"},"versions":{"0.0.1":{"name":"@0bdx/gen-class","version":"0.0.1","description":"Generates files containing JavaScript classes and unit tests, based on a JSON schema.","type":"module","engines":{"node":">= 14.0.0"},"bin":{"gen-class":"bin/gen-class.js"},"preferGlobal":true,"main":"gen-class.js","scripts":{"build:prod":"rollup -c","build:types":"tsc gen-class.js --allowJs --declaration --emitDeclarationOnly","build":"for s in {prod,types};do npm run build:$s;done","preflight:test":"echo \"🧬 test.js\" && node test.js","preflight:types":"tsc gen-class.js --allowJs --checkJs --noEmit","preflight":"for s in {test,types};do npm run preflight:$s;done","test":"echo \"🧪 src/test.js\" && node src/test.js"},"repository":{"type":"git","url":"git+https://github.com/0bdx/gen-class.git"},"keywords":["class","generator","cli"],"author":{"name":"0bdx","email":"0@0bdx.com","url":"0bdx.com"},"license":"MIT","types":"./gen-class.d.ts","bugs":{"url":"https://github.com/0bdx/gen-class/issues"},"homepage":"https://github.com/0bdx/gen-class#readme","devDependencies":{"@0bdx/build-helpers":"^0.0.4","rollup":"^3.20.6"},"dependencies":{"@0bdx/ainta":"^0.0.18"},"gitHead":"ad726fa3ccb01c6b84469d949df65543ab3e21f0","_id":"@0bdx/gen-class@0.0.1","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-b0u5NLV9QF37cst0ehgwiZwmIFNVzplF4SXan/avKy2UjxfzB4QitAVapd7Y8Sy2IezaqTGTJP8+mg7j0NrA8g==","shasum":"9b226856398d9ee66e37a2fe2642d3c4498e6817","tarball":"https://registry.npmjs.org/@0bdx/gen-class/-/gen-class-0.0.1.tgz","fileCount":6,"unpackedSize":3893,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIFMV6wKJZN/ijkTSXHXTcu/jmQ5lYOsaDWFMeZkIgjqrAiBL5+wysqf8xQtTMzTUDa5LyC+byyH0qNZib8l9+ucK/w=="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkQPspACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmqw6A//crLyKi4MB/bq6QrLaJxdUUMx0tFc1FB7u+zX2hr4JS46bfzD\r\nBEDEn5cnhiH8deHVBXO3T/P1GcEFXFmbCCEq/pLbRzlxrIpf42CrCs828amy\r\n0oTWXDqPcRpsHaz5eFIf5/JQnK41YyHuGlbP76R5GfM1GAcxOh6fDl7BRLjw\r\nQusW4wneueHmdntIq2xn6ZPMXa3VA1WzkCkZt06GjtkXLV7aqpw1NlbtruV8\r\nS74NS7Hchnpxd3nGk40eqm6Na88LohPGwAjrg1ABJD/yB8On6ZxZ/fudoUIa\r\nRNZbKqnOvxsTB+lAwSsP5XaifRei30DixEz/YNrRT4CA9b7XRZumEuvS4y88\r\nGqsaEEXCba90hKeyd8XEW9xR0huuHfejXARFg00v1I/G7M6KPXxrZUnTHzif\r\nwRBgGQsGDELnb3+0kd5IFjUdqv/hgBwYtfZpGqv9DvsW3t3M1VUaRoDXK5w2\r\nwn/MUtjuYmmf1GvNg1Y0pkWnSMPWe7xdDItNsr6WV3w5UdtlU+iKiP+IqqmP\r\nku2M7ucdjpDGxQ5tbpzjLf++tVdbw7ILIbjY0jDoKZ81kVZXYENLGXqTyAO3\r\nshqOrT9sjKgyJklm4Z0LqIvuUPS/ZotqN+Az+BE8CX3MfdeCnyXLKw8OKWdV\r\nuY8DnCj59A7jbvzQHClpO6SgErXKV8JPHLU=\r\n=9ga7\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"0bdx","email":"0bdx.com@gmail.com"},"directories":{},"maintainers":[{"name":"0bdx","email":"0bdx.com@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/gen-class_0.0.1_1681980200877_0.061093395900224"},"_hasShrinkwrap":false},"0.0.2":{"name":"@0bdx/gen-class","version":"0.0.2","description":"Generates files containing JavaScript classes and unit tests, based on a JSON schema.","type":"module","engines":{"node":">= 14.0.0"},"bin":{"gen-class":"bin/gen-class.js"},"preferGlobal":true,"main":"gen-class.js","scripts":{"build:prod":"rollup -c","build:types":"tsc gen-class.js --allowJs --declaration --emitDeclarationOnly","build":"for s in {prod,types};do npm run build:$s;done","preflight:test":"echo \"🧬 test.js\" && node test.js","preflight:types":"tsc gen-class.js --allowJs --checkJs --noEmit","preflight":"for s in {test,types};do npm run preflight:$s;done","test":"echo \"🧪 src/test.js\" && node src/test.js"},"repository":{"type":"git","url":"git+https://github.com/0bdx/gen-class.git"},"keywords":["class","generator","cli"],"author":{"name":"0bdx","email":"0@0bdx.com","url":"0bdx.com"},"license":"MIT","types":"./gen-class.d.ts","bugs":{"url":"https://github.com/0bdx/gen-class/issues"},"homepage":"https://github.com/0bdx/gen-class#readme","devDependencies":{"@0bdx/build-helpers":"^0.0.4","@types/node":"^18.15.12","rollup":"^3.20.6"},"dependencies":{"@0bdx/ainta":"^0.0.18"},"gitHead":"9d2977388e01f3ce8943494d3ae5dfae37ee6f9d","_id":"@0bdx/gen-class@0.0.2","_nodeVersion":"16.16.0","_npmVersion":"8.11.0","dist":{"integrity":"sha512-KVdiEG8hl0nf3FJGoGoLzcuv2mPUtWRyWGi12UJR9hVPAvXYskj5pbLmqe0r5yN3ySPRYgmEnPfUbj7m8nDVpg==","shasum":"4c052f5f36de3c3bcc3db21669a6e826858e5513","tarball":"https://registry.npmjs.org/@0bdx/gen-class/-/gen-class-0.0.2.tgz","fileCount":6,"unpackedSize":8911,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCZHekc7ch+buqjgwmE4ZUFTTHjOxWGXg9AbqEhAZP45AIhAL2pRh9WmSOtDk/AaSfsN09oc8pPBAkcwXzzAz53qLKs"}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJkQRvIACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2Vmp3jg/9Eg1BDmxd/Kpm0kfU2A3mwmYxb1DLel3NNlfe4qYCP4hpf0gv\r\nJhz00ny7WBpwT/dtLIFDDw9QHL8bK62rMwE3jUiOxhkCWp8xVeLx3CUGIW2p\r\n3Ix9Qh5KG8bg0UJAo7TjYw3Ymrjsf/wnSIRIsMFntHktwcDym/J2zX4eGvUb\r\nPhRzWvdK+Rdnpcv9kobiurdYy8H2u4dMaYhaE4DGPAP9qWoqiRwOZmtQegs8\r\ng96W1JJW0uQbZkYkVNd/dh+m0vTSHPfp95Eep0Jy6LxSUQ5Ky5RO1US5nuek\r\nIBzsdozyDkfXU76qUfG6+XW0sBJlB0iAnuoQgSwxgJAs0t/L0+h6qRVIDgqx\r\n5wIR/hwZ/piuCojcXmg08hmU1lusX3UErfUXDQAkweHg9LCdyTLyYZmZcWPy\r\nhmAWu1sH8237Y6eNpgpHkxivRfsSKgO1ERuWdkHrRaLftD7mWadbjE8qRIWb\r\nk8UuKb9bW7ofJJlOEAWfW51uuwH5XpUMa5toFI+LHIea0ojYYczjSkJLqdi/\r\nIPF+UwnBtyunxyqMdk5w6L8cUHP2RPItyFdzKbhlPcsv+gwRN+a0cLMjtRc3\r\n2a4KD5UQVkLtAcCqLhqz2g62g2AWD3i26vTf3A780Gcw91h889/CohSYwpDK\r\nf9TZ5fJ451nz4hYHzMw4PNGWNVNk45t8hoI=\r\n=KoJM\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"0bdx","email":"0bdx.com@gmail.com"},"directories":{},"maintainers":[{"name":"0bdx","email":"0bdx.com@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/gen-class_0.0.2_1681988552719_0.9638774877866965"},"_hasShrinkwrap":false}},"time":{"created":"2023-04-20T08:43:20.829Z","0.0.1":"2023-04-20T08:43:21.166Z","modified":"2023-04-20T11:02:33.049Z","0.0.2":"2023-04-20T11:02:32.905Z"},"maintainers":[{"name":"0bdx","email":"0bdx.com@gmail.com"}],"description":"Generates files containing JavaScript classes and unit tests, based on a JSON schema.","homepage":"https://github.com/0bdx/gen-class#readme","keywords":["class","generator","cli"],"repository":{"type":"git","url":"git+https://github.com/0bdx/gen-class.git"},"author":{"name":"0bdx","email":"0@0bdx.com","url":"0bdx.com"},"bugs":{"url":"https://github.com/0bdx/gen-class/issues"},"license":"MIT","readme":"# @0bdx/gen-class\n\n__Generates files containing JavaScript classes and unit tests, based on a JSON schema.__\n\n∅&nbsp; __Version:__ 0.0.2  \n∅&nbsp; __NPM:__ <https://www.npmjs.com/package/@0bdx/gen-class>  \n∅&nbsp; __Repo:__ <https://github.com/0bdx/gen-class>  \n∅&nbsp; __Homepage:__ <https://0bdx.com/gen-class>\n\n@TODO add an overview\n\n## Installation and usage\n\n`gen-class` can be installed as dependency for programmatic use,\nor as a command line app.\n\n### __Installation and usage as a dev-dependency__\n\n```sh\nnpm install @0bdx/gen-class --save-dev\n```\n\n```js\nimport genClass from '@0bdx/gen-class';\n\nconsole.log(genClass({\n    name: 'MyClass',\n    instance: {\n        scalars: [\n            { isOk: { type: 'boolean' } }\n        ]\n    }\n}));\n```\n\n### __Installation and usage as a command line app__\n\nMake a folder called 'my/src/classes/', and a file called 'basic-class.json':\n```json\n{\n    \"name\": \"MyClass\",\n    \"instance\": {\n        \"scalars\": [\n            { \"isOk\": { type: \"boolean\" } }\n        ]\n    }\n}\n```\n\n```sh\nnpm install @0bdx/gen-class --global\ngen-class --help\ngen-class --version\ngen-class examples/example-1/basic-class.json --output examples/example-1\ngen-class my-class-definitions.json --output my/src/classes/\n```\n","readmeFilename":"README.md"}