@sheetxl/studio-vanilla
Version:
SheetXL Studio - Vanilla entry point for integrating SheetXL UI.
7 lines (6 loc) • 976 B
JavaScript
(function(e){typeof define=="function"&&define.amd?define(e):e()})(function(){"use strict";/**
* @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.6.4
*
* (C) 2025-present SheetXL Inc. & Michael T. Ford
* License: The license can be found at https://www.sheetxl.com/license.
*/(()=>{const e=document.currentScript,o=()=>{if(!e)return void console.error("script tag is not available. Ensure the module tag is not used.");const r=e.dataset.target??"#sheetxl",t={...e.dataset},d=t.licenseKey;delete t.target,delete t.licenseKey;const i=e.src,c=new URL("./index.js",i).href;import(c).then(n=>{const a=document.querySelector(r);a?n.SheetXL.attachStudio({selector:a,licenseKey:d},t):console.error(`SheetXL: Target element "${r}" not found.`)}).catch(n=>{console.error(`SheetXL: Failed to load the main application from ${c}`,n)})};document.readyState==="loading"?document.addEventListener("DOMContentLoaded",o):o()})()});