A library for mapping content to a topper on FT.com and the App.
- Node >18.x
git clone https://github.com/Financial-Times/n-map-content-to-topper.git
cd n-map-content-to-topper
npm install
In order to run the tests locally you'll need to run:
npm run test
npm install @financial-times/n-map-content-to-topper
const {
mapContentToTopper
} = require('@financial-times/n-map-content-to-topper');
const topper = mapContentToTopper(content, flags);
The project is released automatically to npm via Github Releases. Create a release, and name the tag with the Semantic Versioning version you want. The CircleCI build for the tag will release that version to npm.