Skip to content

Getting Started ​

Datastripes ships as one npm package, @datastripes/forecast. The root entry is the framework-agnostic core; each UI framework gets its own subpath entry point inside the same package:

Import pathPurpose
@datastripes/forecastForecasting engine, auto-discovery, licensing client, types. No UI framework dependency.
@datastripes/forecast/reactReact components (DatastripesForecast and friends) + useWasmForecast hook.
@datastripes/forecast/vueVue 3 components (DatastripesForecast and friends) + useWasmForecast composable.
@datastripes/forecast/angularStandalone Angular components (DatastripesForecastComponent and friends), built in Angular Package Format.
@datastripes/forecast/elementsA <datastripes-forecast-studio> Custom Element (plus companion elements) for any stack.

Every framework entry re-exports the core, so one import covers components, hooks, and types.

Install ​

bash
npm install @datastripes/forecast

React, Vue, and Angular are optional peer dependencies: installing the package never pulls in a UI framework. Install the one your app uses (most apps already have it):

bash
npm install react react-dom                # for @datastripes/forecast/react
npm install vue                            # for @datastripes/forecast/vue
npm install @angular/core @angular/common  # for @datastripes/forecast/angular
# @datastripes/forecast/elements needs no framework

Minimal example (core only) ​

ts
import { executeForecast } from '@datastripes/forecast';

const result = await executeForecast({
  data: [{ date: '2024-01-01', value: 120 }, /* ... */],
  algorithm: 'prophet_lite',
  horizon: 30
});

console.log(result.points, result.metrics, result.licenseStatus);

See the framework-specific installation pages in this guide, and Licensing for how the trial/paid tiers work.