Skip to content
This repository was archived by the owner on Oct 4, 2023. It is now read-only.

Commit 8fae476

Browse files
shavidzetXanderLuciano
authored andcommitted
fix web build (#726)
1 parent b1f069a commit 8fae476

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

template/src/index.ejs

+5-3
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,11 @@
1313
<body>
1414
<div id="app"></div>
1515
<!-- Set `__static` path to static files in production -->
16-
<script>
17-
if (process.env.NODE_ENV !== 'development') window.__static = require('path').join(__dirname, '/static').replace(/\\/g, '\\\\')
18-
</script>
16+
<% if (!process.browser) { %>
17+
<script>
18+
if (process.env.NODE_ENV !== 'development') window.__static = require('path').join(__dirname, '/static').replace(/\\/g, '\\\\')
19+
</script>
20+
<% } %>
1921

2022
<!-- webpack builds are automatically injected -->
2123
</body>

0 commit comments

Comments
 (0)