diff --git a/index.html b/index.html index f8dbda5..8137a68 100644 --- a/index.html +++ b/index.html @@ -2,12 +2,12 @@ +

Testing index.js Module Import

diff --git a/index.js b/index.js index d0c0d44..0c85009 100644 --- a/index.js +++ b/index.js @@ -1,10 +1,11 @@ -export const $ = (selector) => +const $ = (selector) => { const el = document.querySelector(selector) el.render = (html) => el.innerHTML = html el.inject = (html) => el.insertAdjacentHTML('beforeend', html) + el.ontop = (html) => el.insertAdjacentHTML('beforebegin', html) return el; }; -export const $$ = (selector) => return document.querySelectorAll(selector) -export const _ = msg => console.log(msg); // _('hello') +const $$ = (selector) => { return document.querySelectorAll(selector)} +const _ = msg => console.log(msg); // _('hello') diff --git a/package.json b/package.json index 622aa47..74c5c49 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "qthtml", - "version": "0.2.0", + "version": "0.3.0", "description": "", "main": "index.js", "type": "module",