BlendDuck Widgets are powerful, reusable UI components that can be easily integrated into your projects on the BlendDuck platform. These widgets enhance your ability to visualize data, add interactivity, and create compelling visual experiences.
A Widget is an extension of an Element. You can create a project with Widgets:
Copy
import BlendDuck, { Project, Clip, Widget } from "@blendduck/node-sdk";const client = new BlendDuck({ apiKey: process.env.BLENDDUCK_API_KEY});const project = new Project();const clip1 = new Clip(5); // 5-second clipproject.addClip(clip1);const widget = new Widget({ scope: 'core', widgetId: 'counter'});clip1.elements.push(widget);
This script creates a Widget with the scope set to core and the widgetId set to counter. Its function is to quickly create number transition animations. You can view all Widgets on the Built-in Widgets page.