reactjs - Need a workaround for Adobe SnapSVG-animator running in React.js -


snapsvg extension adobe animate.cc 2017 able create interactivity , animations web. i'm trying use exported snapsvg adobe animate.cc project in react js webapplication.

what did far

  1. published html file snapsvg project(animate.cc 2017)

  2. copyed custom json file created snapsvg project in animate.cc in react app.

  3. installed snapsvg npm install in react app.

  4. imported js file copyed html publication created animate.cc importing code. ( snapsvg-animator isn't available in npm)

  5. the custom json file animate.cc/snap svg project loaded async , added svganim(snapsvganimator.min.js) function object create svg animation in de browser.

the code

import axios 'axios'; import snapsvg 'snapsvg'; import { svganim } './snapsvganimator.min.js';  let jsonfile = "circle.json",                  responsetype: 'json';  componentdidmount(){     axios.get(jsonfile)       .then(response => {         const json = response.request.responsetext;         const animatedsvg = new svganim(json);       });   }  

problem

the snapsvganimator.min.js creates warnings , errors when it's imported in jsx file. looks going wrong compiling these code.

✖ 1557 problems (110 errors, 1447 warnings)enter image description here


Comments

Popular posts from this blog

python Tkinter Capturing keyboard events save as one single string -

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

javascript - Z-index in d3.js -