Open CorvusCorrax opened 7 years ago
did you try importing it into a variable in the script where you initialize the addToHomescreen?
import addToHomescreen from '../vendor/addtohomescreen.min';
followed by
addToHomescreen({ skipFirstVisit: true, startDelay: 15, });
This works for me with webpack:
import addToHomescreen from 'add-to-homescreen/dist/addtohomescreen.min';
import addToHomescreenCSS from 'add-to-homescreen/dist/style/addtohomescreen.css';
window.addToHomescreen()
When i import npm addToHomescreen module (v5.0.0) using webpack, i get an "addToHomescreen is not defined" on
addToHomescreen()