Gage Hendy Ya Boy
Gage Hendy Ya Boy

Reputation: 1564

External libraries in React

I am working on a site using react, and I need to install mojs, mojs-timeline, and mojs-curve-editor. None of these are npm packages, what is the best way to include them to be used within react?

I found this post that looks like it references a helpful article in React's documentation but it has been deleted I guess as it just redirects you to the tutorial page.

I can download the files, or source them externally, whatever is best for this case.

I've seen a lot of talk about using Webpack, but I'm not too familiar with it and my attempts at including it in the Webpack config have been unsuccessful.

Any and all help is appreciated!

Upvotes: 2

Views: 1191

Answers (1)

canaan seaton
canaan seaton

Reputation: 6868

You should be able to simply link them in your index.html file like so...

<script type="text/javascript" src="/static/path/to/file/or/cdn"></script>

Upvotes: 4

Related Questions