Skip to main content

Betterer API

Betterer has a JavaScript API which can be used to start a run programatically.

betterer()#

Run Betterer with given options.

Usage:

import { betterer } from '@betterer/betterer';
const summary = await betterer(options);

Args:

Returns: BettererSummary

betterer.watch()#

Create a BettererRunner with given options. Starts up a file watcher in the current directory.

Usage:

import { betterer } from '@betterer/betterer';
const runner = await betterer.watch(options);

Args:

Returns: BettererRunner

betterer.runner()#

Create a BettererRunner with given config.

Usage:

import { betterer } from '@betterer/betterer';
const runner = await betterer.runner(options);

Args:

Returns: BettererRunner