Skip to content

Commit a564907

Browse files
committed
[BREAKING] dropping npm + js dependencies
1 parent cd147f7 commit a564907

18 files changed

+34
-23074
lines changed

README.md

+5-12
Original file line numberDiff line numberDiff line change
@@ -207,22 +207,15 @@ You can go to localhost:1313 and this theme should be visible.
207207

208208
Build [SASS](https://sass-lang.com/install) updates by downloading [Dart SASS](https://github.com/sass/dart-sass/releases/tag/1.45.0)
209209

210-
`sass sass/style.scss static/css/style.css`
211-
212-
Update `includes.html` with the appropriate CSS file (default is style.min.css):
213-
214-
```
215-
<!-- CSS -->
216-
<link rel="stylesheet" href="/css/style.min.css">
217-
```
210+
> Development
218211
219-
### Javascript
212+
`sass sass/style.scss static/css/style.css`
220213

221-
Hugo Now supports Bootstrap JS but Github Pages and others disable Javascript. This is available for sites hosted on S3 and elsewhere.
214+
> Production
222215
223-
Build JS updates by running `gulp` (development) or `gulp dist` (production)
216+
`sass sass/style.scss static/css/style.css --style compressed`
224217

225-
Update `javascript.html` with the appropriate JS files (defaults are bootstrap dependencies).
218+
Set the `HUGO_ENV` variable to `production` to use the minified CSS.
226219

227220
## License
228221

gulpfile.js

-60
This file was deleted.

layouts/partials/footer.html

-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
</footer>
66
</div>
77
</div>
8-
{{ partial "javascript.html" . }}
98
{{ partial "analytics.html" . }}
109
</body>
1110
</html>

layouts/partials/includes.html

+4
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,6 @@
11
<!-- CSS -->
2+
{{ if eq (getenv "HUGO_ENV") "production" }}
3+
<link rel="stylesheet" href="/css/style.min.css">
4+
{{else}}
25
<link rel="stylesheet" href="/css/style.css">
6+
{{end}}

layouts/partials/javascript.html

-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +0,0 @@
1-
<!-- jQuery first, then Tether, then Bootstrap JS. -->
2-
<script src="/js/dist/vendor/jquery/jquery.min.js"></script>
3-
<script src="/js/dist/vendor/tether/tether.min.js"></script>
4-
<script src="/js/dist/vendor/bootstrap/bootstrap.min.js"></script>

0 commit comments

Comments
 (0)