Rodwan Bakkar
Rodwan Bakkar

Reputation: 484

integrating react project into another react project

I am very new to react. I grabbed the petclinic project from github (https://github.com/spring-petclinic/spring-petclinic-reactjs) to run it and understand how react works. I want to add plugins to this project (plugins are other react projects as I understand), The plugin I want to add is a datatable (https://github.com/rishabhbits038/react-tabelify) which is another react project. My question is how to integrate one react project inside the other. in jquery it is direct, just including the .js file in the project but in react it does not seem that obvious.

Upvotes: 0

Views: 1137

Answers (1)

Dane
Dane

Reputation: 9583

From inside the petclinic project, run

npm install react-tabelify

and import the component you want use as:

import Tabelify from 'react-tabelify';

should work, as the second library is registered with npm

Upvotes: 1

Related Questions