Libaries
In order to support implementation of Trilly, we provide couple of libraries. This section will help you understand how to use them to use your content.
Trilly provides two libraries for JS/TS projects:
@trillyapp/vanilla
- offers methods to create trilly client, manage context, fetch data and get specific content fields.@trillyapp/react
- offers react hooks to help manage trilly context and fetch data in React environment.
@trillyapp/vanilla
Create client
import {createClient} from '@trillyapp/vanilla';
const client = createClient({
apiKey: process.env.TRILLY_API_KEY,
});