Skip to content
Branch: master
Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
src
test-data
.dockerignore
.gitignore
Dockerfile
README.md
docker-compose.test.yml
entrypoint.sh
package-lock.json
package.json
tsconfig.json

README.md

Aviation

Aviation Client for Typescript

npm version npm download per month npm license

This library enables you to check against an Aviation Server whether a feature is supposedly enabled or not.

Usage

To add the library to your project:

$ npm i @neoskop/aviation-client

To check for a feature:

let client: AviationClient = aviation().endpoint('http://localhost:8080').token('sup3rs3cr3t').mix();

client.feature('test-feature-1').then(f => {
  if (f.evaluate()) {
    console.log('feature is enabled!');
  } else {
    console.log('feature is disabled!');
  }
}).catch((err) => {
  console.log('could not retrieve feature from server!', err);
});

Test suite

To run integration tests in case you checked out the repository (awesome!):

$ docker-compose -f docker-compose.test.yml up --abort-on-container-exit --build
You can’t perform that action at this time.