diff --git a/scripts/external/check.js b/scripts/external/check.js new file mode 100644 index 0000000..3f01663 --- /dev/null +++ b/scripts/external/check.js @@ -0,0 +1,19 @@ +/* +check.js + +Check if a website is supported. +*/ + +import filters from '/scripts/filters.js'; + +export default class check { + /* + Check if an e-commerce platform is supported. + + @param {string} URL + @returns {object} the support state + */ + static async platform (URL = window.location.href) { + return (await ((new filters).select(URL))); + } +} \ No newline at end of file