![Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility](https://cdn.sanity.io/images/cgdhsj6q/production/97774ea8c88cc8f4bed2766c31994ebc38116948-1664x1366.png?w=400&fit=max&auto=format)
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
predeploy-builder
Advanced tools
a builder used to generate api at apiary and update client lib on npm
A builder used to generate an api at apiary/generate client lib and publish client lib to npm
##Requirements
1.Install swagger-codegen command line tools at https://github.com/swagger-api/swagger-codegen
2.npm install -g cli-codegen
3.Easiest to run this code while app is running and swagger is at localhost:8000/swagger.json
4.Look at https://www.npmjs.com/package/cli-codegen if swagger location different.
##Example First:
npm install predeploy-builder
Next:
var builder = require('builder');
var config = {
client: { //required for .makeClientLib(),writePackage() and publish()
file: 'File name' //not required,
classname: 'classname for javascript gen' //required for js
language: 'language to generate lib for' //required
}
apiary : {
token: 'your apiary account token' //required
name: 'your apiary api name' //required,
sub_domain: 'This is used to point readme to your proper api location in apiary' //required for writeReadme()
}
package: { //Anything not passed in will be pulled from project package file that was used to generate lib
name: 'name that will go in package' //not required
version: 'version that will go in package' //not required
description: 'description that will go in package' //not required
author: 'author that will go in package' //not required
license: 'license that will go in package' //not required
}
port: 'port your api is hosted on' // will default to 8000 if not passed in
}
var build = new builder(config);
###genDocs: Note: right now you can only push docs that are in .yaml format
build.genDocs( (err,result) => {} )
//This Method is used to publish api to apiary
###makeClientLib:
build.makeClientLib( (err,result => {} )
//This Method is used to generate client library for a language based on config from earlier.
###writePackage
build.writePackage( (err,result) => {} )
//this Method is used to write a package file in order to prep for npm publish
###writeReadme
build.writeReadme ( (err,result) => {} )
//This Method is used to write a readme.md pointing to apiary docs.
###publish
build.publish( (err,result) => {} )
//This method is used to publish the newly made client lib to npm
###Note: makeClientLib(),writePackage() and publish() should all be used togeather. Only makeClientLib() can work on its own.
FAQs
a builder used to generate api at apiary and update client lib on npm
The npm package predeploy-builder receives a total of 1 weekly downloads. As such, predeploy-builder popularity was classified as not popular.
We found that predeploy-builder demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.