Browse Source

Fix asset paths when baseURL has sub-folder (#103)

See #97
tags/2.3
Anthony Fok 6 years ago
parent
commit
89c26174a4
2 changed files with 2 additions and 2 deletions
  1. 1
    1
      layouts/_default/baseof.html
  2. 1
    1
      layouts/partials/site-scripts.html

+ 1
- 1
layouts/_default/baseof.html View File

@@ -19,7 +19,7 @@

{{ $stylesheet := .Site.Data.webpack_assets.app }}
{{ with $stylesheet.css }}
<link href="{{ absURL (printf "%s%s" "/dist/" .) }}" rel="stylesheet">
<link href="{{ relURL (printf "%s%s" "dist/" .) }}" rel="stylesheet">
{{ end }}

{{ range .Site.Params.custom_css }}

+ 1
- 1
layouts/partials/site-scripts.html View File

@@ -1,4 +1,4 @@
{{ $script := .Site.Data.webpack_assets.app }}
{{ with $script.js }}
<script src="{{ absURL (printf "%s%s" "/dist/" .) }}"></script>
<script src="{{ relURL (printf "%s%s" "dist/" .) }}"></script>
{{ end }}

Loading…
Cancel
Save