Write new index.js for the package
parent
8d8037ee1a
commit
73b54c385a
|
@ -1,8 +1,10 @@
|
||||||
import initializeShareon from "./shareon";
|
import initializeShareon from "./shareon";
|
||||||
import "./style.css";
|
import "./style.css";
|
||||||
|
|
||||||
window.onload = () => {
|
// TODO: update README
|
||||||
|
const s = document.currentScript;
|
||||||
|
if (s && s.hasAttribute("init")) {
|
||||||
initializeShareon();
|
initializeShareon();
|
||||||
};
|
}
|
||||||
|
|
||||||
export default initializeShareon;
|
export default initializeShareon;
|
Loading…
Reference in New Issue