cdb233e4ee
* enable codeQL * update image * remove redundant changes * update image * [Test] just update image * update node version |
||
---|---|---|
.vscode | ||
browser | ||
docs | ||
lib | ||
test | ||
.editorconfig | ||
.eslintrc | ||
.gitignore | ||
.nsprc | ||
.prettierrc | ||
CONTRIBUTING.md | ||
LICENSE | ||
README.md | ||
RELEASE_NOTES.md | ||
azure-pipelines-securitytasks.yml | ||
azure-pipelines.yml | ||
bower.json | ||
gulpfile.js | ||
index.d.ts | ||
index.js | ||
package-lock.json | ||
package.json |
README.md
Yet another sway
A library that simplifies Swagger integrations. This library handles the minutiae of loading Swagger documents (local and remote), resolving references (local, remote), building an object model and providing you with a rich set of APIs for things like Swagger document validation, request/response validation, etc. For more details on the available APIs, please view the API Documentation.
Sway will always be built around the latest stable release of Swagger, which happens to be version 2.0
right now.
This means that its APIs and object model will be specific to that version of Swagger and supporting any other versions
of Swagger will require a conversion step prior to using Sway.
Project Badges
Installation
sway is available for both Node.js and the browser. Installation instructions for each environment are below.
Browser
Installation for browser applications can be done via Bower or by downloading a standalone binary.
Using Bower
bower install sway --save
Standalone Binaries
The standalone binaries come in two flavors:
- sway-standalone.js: 6,784kb, full source and source maps
- sway-standalone-min.js: 812kb, minified, compressed and no source map
Note: I realize these binaries are big and I'm working on making them smaller. Unfortunately, some of this is out of my control without rewriting some of the core features provided by third-party libraries currently contributing to the size issue.
Node.js
Installation for Node.js applications can be done via NPM.
npm install sway --save
Documentation
The documentation for this project can be found here: /docs/README
Of course, if you just want a quick link to the API documentation, that would be here: /docs/API.md
Contributing
This project uses Gulp for building so npm install -g gulp
once you clone this project. Running gulp
in the
project root will lint check the source code and run the unit tests.