EValue widget: Retirement Forecast
Contents
Description
@ev-uk/retirement-forecast
is an EValue widget that can be added to an existing website
Install
The widget can be installed by running one of the following commands
npm i @ev-uk/retirement-forecast
yarn add @ev-uk/retirement-forecast
Usage
The widget can be imported into a TypeScript project as follows:
import type { TApiParameter, TInitConfig, TRetirementForecastProps } from '@ev-uk/retirement-forecast';
import { RetirementForecastWidget } from '@ev-uk/retirement-forecast';
const api: TApiParameter = {
annuityUrl: '<ANNUITY_URL>'
}
const config: TInitConfig = {
api,
...other parameters...
}
const props: TRetirementForecastProps = {
config
}
export const App = () => {
return (
RetirementForecastWidget(props)
)
}
Parameters
Name | Type | Required | Effects | Description |
---|---|---|---|---|
annuityUrl | string | ✓ | API | The url address to send API requests to |
company | string | API | ||
configReference | string | API | The API company that the implementation is associated with. This should be passed into any API calls highlighted in the API section | |
token | string | API | ||
brandColor | string | Widget | ||
chartColor | string | Widget | ||
currency | string | Widget |
| | riskLevels | number | | User |