How to add plugin in Frameworks7

Hello,

I have searched the forum, but I can’t find an answer to my question.

I am trying to add a plugin (Fabric.js) to Frameworks7, but I don’t know where to put the plugin.

I want to use the plugin on a different page than the index.html. I think this is an elementary question, but I have tried many ways to add it. Nothing seems to work. I can’t find anything about how to add a plugin in the documentation either.

If I am asking a question that isn’t appropriate in this form, I apologize ahead of time.

I’d be very appreciative of your help in guiding me to somewhere that I can find an answer.

Thank you,
-C

do you use webpack? if so;
npm i fabric

in the page you want to use fabric;

import { fabric } from 'fabric'

const c = new fabric.Canvas('c', {...})

or just add de js in index.html and use it, read the doc of fabric for more info.

1 Like

Thank you for your help. I’m going to give your solution a try. :slight_smile: