Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

apibake

Package Overview
Dependencies
Maintainers
1
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

apibake - npm Package Compare versions

Comparing version 0.1.2 to 0.1.3

10

dist/pdf-writer.js

@@ -181,3 +181,3 @@ "use strict";

this.text(': ', { continued: true });
this.styledText(fieldType, { fillColor: this.colorAccent }, {
this.styledText(`${fieldType};`, { fillColor: this.colorAccent }, {
goTo: (_c = field.type) === null || _c === void 0 ? void 0 : _c.anchor,

@@ -205,6 +205,12 @@ underline: ((_d = field.type) === null || _d === void 0 ? void 0 : _d.anchor) ? true : false

enumValues(values) {
this.text('Values: ', { continued: true });
this.text('Values: ');
this.doc.moveUp();
const nextLineIndent = this.doc.x + this.indentStep;
const indent = this.doc.widthOfString('Values: ') - this.indentStep;
values.forEach((value, index, array) => {
const str = (index < array.length - 1) ? `${value}, ` : value;
const continued = (index < array.length - 1) ? true : false;
if (index === 0) {
this.text(str, { x: nextLineIndent, indent, continued });
}
this.text(str, { continued });

@@ -211,0 +217,0 @@ });

19

package.json
{
"name": "apibake",
"version": "0.1.2",
"description": "OpenAPI to PDF doc generator.",
"version": "0.1.3",
"description": "OpenAPI to PDF generator.",
"keywords": [
"OpenAPI",
"Open API",
"Swagger",
"REST API",
"OpenAPI",
"Open API",
"PDF",
"generator",
"PDF generator",
"doc generator",
"API spec generator",
"API doc generator",
"PDF generator",
"REST API",
"OpenAPI",
"Swagger"
"API doc generator"
],

@@ -14,0 +19,0 @@ "author": "Illya Sikeryn",

# ApiBake
Creates REST API PDF spec from OpenAPI .json or .yaml files. Supports OpenAPI 3.0.0.
Convert OpenAPI spec to PDF. Supports OpenAPI 3.0.0+ json and yaml.
## Quick start
**Quick start:**

@@ -7,0 +7,0 @@ npm install -g apibake

@@ -231,3 +231,3 @@ import fs from 'fs';

this.text(': ', { continued: true });
this.styledText(fieldType, { fillColor: this.colorAccent }, {
this.styledText(`${fieldType};`, { fillColor: this.colorAccent }, {
goTo: field.type?.anchor,

@@ -259,6 +259,13 @@ underline: field.type?.anchor ? true : false

enumValues(values: string[]) {
this.text('Values: ', { continued: true });
this.text('Values: ');
this.doc.moveUp();
const nextLineIndent = this.doc.x + this.indentStep;
const indent = this.doc.widthOfString('Values: ') - this.indentStep;
values.forEach((value, index, array) => {
const str = (index < array.length - 1) ? `${value}, ` : value;
const continued = (index < array.length - 1) ? true : false;
if (index === 0) {
this.text(str, { x: nextLineIndent, indent, continued });
}
this.text(str, { continued });

@@ -265,0 +272,0 @@ });

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc