Write new index.js for the package

pull/45/head
Nikita Karamov 2022-02-10 20:32:40 +01:00
parent 8d8037ee1a
commit 73b54c385a
No known key found for this signature in database
GPG Key ID: 3C8E688C96EEB9C9
1 changed files with 4 additions and 2 deletions

View File

@ -1,8 +1,10 @@
import initializeShareon from "./shareon";
import "./style.css";
window.onload = () => {
// TODO: update README
const s = document.currentScript;
if (s && s.hasAttribute("init")) {
initializeShareon();
};
}
export default initializeShareon;