metatroncubeswdev e116a6c87a fix: Theme App Extension only allows assets/blocks/snippets/locales dirs
`shopify app dev` failed dev preview with "Only assets, blocks, snippets,
locales directories are allowed" — the widget's TypeScript source lived in
extensions/datetime-widget/src/, which isn't one of the four directories a
Theme App Extension may contain. Moved it to widget-src/datetime-widget/
(a plain, non-extension folder outside extensions/) and updated
build:widget's esbuild input path accordingly; the bundled output still
lands in the same place (extensions/datetime-widget/assets/).

Also fixed a theme-check warning surfaced during the same run:
`script_tag` renders a parser-blocking <script> with no way to defer it —
switched to a manual <script defer> tag for the widget's JS asset.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-23 21:51:54 -04:00

11 lines
235 B
Plaintext

{{ 'datetime-widget.css' | asset_url | stylesheet_tag }}
<script src="{{ 'datetime-widget.js' | asset_url }}" defer="defer"></script>
{% schema %}
{
"name": "t:app_embed.name",
"target": "body",
"settings": []
}
{% endschema %}