Skip to main content

Common Ninja React Library

The commonninja-react library is a small library that allows you to render Common Ninja widgets in a React or Next.js application. This guide will help you get started with using the library in your project.

Installation

You can install the library via npm or yarn.

npm install commonninja-react
# or
yarn add commonninja-react

Usage

Importing the Library

To use the commonninja-react library, you need to import it into your React component.

import { CommonNinjaWidget } from 'commonninja-react';

Rendering a Widget

You can render a widget by using the CommonNinjaWidget component and providing the necessary props.

const MyComponent = () => {
return (
<div>
<CommonNinjaWidget widgetId="your-widget-id" />
</div>
);
};

export default MyComponent;

Additional Information

For more information, visit the commonninja-react GitHub repository.

If you have any questions or need further assistance, please reach out to our support team.