Skip to content

Commit c22fee0

Browse files
committed
prodify rewrite
1 parent d48fae4 commit c22fee0

10 files changed

Lines changed: 200 additions & 407 deletions

File tree

.claude/settings.local.json

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"permissions": {
3+
"allow": [
4+
"mcp__shopify-dev-mcp__learn_shopify_api",
5+
"mcp__shopify-dev-mcp__validate_theme"
6+
]
7+
},
8+
"enableAllProjectMcpServers": true,
9+
"enabledMcpjsonServers": [
10+
"shopify-dev-mcp"
11+
]
12+
}

snippets/vite-tag.liquid

Lines changed: 24 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,28 @@
66
assign entry = entry | default: vite-tag
77
assign path = entry | replace: '~/', '../' | replace: '@/', '../'
88
%}
9-
{% if path == "/src/entrypoints/theme.css" or path == "theme.css" %}
10-
{{ 'theme.Bo3MPvT-.min.css' | asset_url | split: '?' | first | stylesheet_tag: preload: preload_stylesheet }}
11-
{% elsif path == "/src/entrypoints/theme.js" or path == "theme.js" %}
12-
<script src="{{ 'theme.D9J8CyOY.min.js' | asset_url | split: '?' | first }}" type="module" crossorigin="anonymous"></script>
13-
{% elsif path == "/src/js/prodify/index.ts" or path == "../js/prodify/index.ts" %}
14-
<script src="{{ 'index.BZgz5Rbq.min.js' | asset_url | split: '?' | first }}" type="module" crossorigin="anonymous"></script>
9+
{% liquid
10+
assign path_prefix = path | slice: 0
11+
if path_prefix == '/'
12+
assign file_url_prefix = 'https://127.0.0.1:3000'
13+
else
14+
assign file_url_prefix = 'https://127.0.0.1:3000/src/entrypoints/'
15+
endif
16+
assign file_url = path | prepend: file_url_prefix
17+
assign file_name = path | split: '/' | last
18+
if file_name contains '.'
19+
assign file_extension = file_name | split: '.' | last
20+
endif
21+
assign css_extensions = 'css|less|sass|scss|styl|stylus|pcss|postcss' | split: '|'
22+
assign is_css = false
23+
if css_extensions contains file_extension
24+
assign is_css = true
25+
endif
26+
%}
27+
<script src="https://127.0.0.1:3000/@vite/client" type="module"></script>
28+
<script id="hot-reload-client" src="https://cdn.jsdelivr.net/npm/@shopify/theme-hot-reload/dist/theme-hot-reload.min.js" type="module"></script>
29+
{% if is_css == true %}
30+
<link rel="stylesheet" href="{{ file_url }}" crossorigin="anonymous">
31+
{% else %}
32+
<script src="{{ file_url }}" type="module"></script>
1533
{% endif %}

src/js/prodify/const.ts

Lines changed: 0 additions & 20 deletions
This file was deleted.

src/js/prodify/dom.ts

Lines changed: 0 additions & 140 deletions
This file was deleted.

src/js/prodify/events.ts

Lines changed: 0 additions & 42 deletions
This file was deleted.

src/js/prodify/helpers.ts

Lines changed: 0 additions & 56 deletions
This file was deleted.

0 commit comments

Comments
 (0)