Skip to content

Commit 67f0a6e

Browse files
committed
Initial commit
0 parents  commit 67f0a6e

File tree

109 files changed

+8637
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

109 files changed

+8637
-0
lines changed

.dependabot/config.yml

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
version: 1
2+
update_configs:
3+
- package_manager: javascript
4+
directory: /
5+
update_schedule: live
6+
allowed_updates:
7+
- match:
8+
update_type: security
9+
automerged_updates:
10+
- match:
11+
dependency_type: all
12+
update_type: in_range
13+
version_requirement_updates: widen_ranges

.editorconfig

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# editorconfig.org
2+
3+
root = true
4+
5+
[*]
6+
indent_style = space
7+
indent_size = 2
8+
end_of_line = lf
9+
charset = utf-8
10+
trim_trailing_whitespace = true
11+
insert_final_newline = true

.eslintignore

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
assets/js/vendor
2+
node_modules

.eslintrc.json

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
{
2+
"env": {
3+
"browser": true,
4+
"commonjs": true,
5+
"es6": true,
6+
"node": true
7+
},
8+
"extends": "eslint:recommended",
9+
"globals": {
10+
"Atomics": "readonly",
11+
"SharedArrayBuffer": "readonly"
12+
},
13+
"parserOptions": {
14+
"ecmaVersion": 2018
15+
},
16+
"rules": {
17+
"no-console": 0,
18+
"quotes": ["error", "single"],
19+
"comma-dangle": [
20+
"error",
21+
{
22+
"arrays": "always-multiline",
23+
"objects": "always-multiline",
24+
"imports": "always-multiline",
25+
"exports": "always-multiline",
26+
"functions": "ignore"
27+
}
28+
]
29+
}
30+
}

.gitignore

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
functions
2+
node_modules
3+
public
4+
resources
5+
yarn-error.log

.stylelintignore

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
assets/scss/common/_syntax.scss
2+
assets/scss/vendor
3+
node_modules

.stylelintrc.json

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
{
2+
"extends": "stylelint-config-standard",
3+
"rules": {
4+
"no-empty-source": null,
5+
"string-quotes": "double",
6+
"at-rule-no-unknown": [
7+
true,
8+
{
9+
"ignoreAtRules": [
10+
"extend",
11+
"at-root",
12+
"debug",
13+
"warn",
14+
"error",
15+
"if",
16+
"else",
17+
"for",
18+
"each",
19+
"while",
20+
"mixin",
21+
"include",
22+
"content",
23+
"return",
24+
"function",
25+
"tailwind",
26+
"apply",
27+
"responsive",
28+
"variants",
29+
"screen"
30+
]
31+
}
32+
]
33+
}
34+
}

.travis.yml

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
dist: xenial
2+
sudo: required
3+
4+
language: node_js
5+
node_js:
6+
- "lts/*"
7+
8+
install:
9+
- wget "https://github.com/gohugoio/hugo/releases/download/v${HUGO_RELEASE}/hugo_extended_${HUGO_RELEASE}_Linux-64bit.deb"
10+
- sudo dpkg -i hugo*.deb
11+
- yarn install
12+
13+
script:
14+
- hugo version
15+
- yarn test
16+
- yarn clean
17+
- yarn build
18+
19+
env:
20+
global:
21+
- PRODUCTION=true
22+
- HUGO_RELEASE=0.60.1

CHANGELOG.md

+76
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
# Changelog
2+
All notable changes to this project will be documented in this file.
3+
4+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
5+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6+
7+
## [Unreleased]
8+
9+
## [1.2.1] - 2020-03-31
10+
### Added
11+
- version to package.json - [issue 23](https://github.com/h-enk/hyas/issues/23)
12+
- `copy:deps` to build command - [issue 22](https://github.com/h-enk/hyas/issues/22)
13+
- `clean:deps` command
14+
15+
## [1.2.0] - 2020-03-30
16+
### Added
17+
- ga-lite - [issue 15](https://github.com/h-enk/hyas/issues/15)
18+
- copy script for dep resources - [issue 14](https://github.com/h-enk/hyas/issues/14)
19+
- flag `--minify` to `build` command
20+
21+
### Changed
22+
- Bumped `[build.environment]` `netlify.toml`
23+
- Bumped dependencies `package.json`
24+
- Update security headers - [issue 17](https://github.com/h-enk/hyas/issues/17)
25+
- `README.md`
26+
- `robots` tag logic in `seo.html`
27+
28+
### Removed
29+
- favicon - [issue 12](https://github.com/h-enk/hyas/issues/12)
30+
31+
## [1.1.0] - 2020-02-06
32+
### Added
33+
- `<link rel="shortcut icon" href="/path/to/favicon.ico">` - [issue 12](https://github.com/h-enk/hyas/issues/12)
34+
- breadcrumbList structured data - [issue 11](https://github.com/h-enk/hyas/issues/11)
35+
- body classes - [issue 10](https://github.com/h-enk/hyas/issues/10)
36+
- `.stylelintignore` - [issue 9](https://github.com/h-enk/hyas/issues/9)
37+
- `.eslintignore` - [issue 8](https://github.com/h-enk/hyas/issues/8)
38+
39+
### Changed
40+
- default theme - [issue 7](https://github.com/h-enk/hyas/issues/7)
41+
- bumped dependency `lazysizes` to `^5.2`
42+
- bumped dependency `HUGO_VERSION` to `0.63.2`
43+
44+
## [1.0.1] - 2019-12-20
45+
### Added
46+
- custom `layouts/rss.xml` with page option `feed_exclude: true` - [issue 5](https://github.com/h-enk/hyas/issues/5)
47+
- content `'./content/**/*.md',` to `postcss.config.js` - [issue 2](https://github.com/h-enk/hyas/issues/2)
48+
49+
### Changed
50+
- set `canonifyURLs = false` in `/config/production/config.toml` and `/config/staging/config.toml` - [issue 3](https://github.com/h-enk/hyas/issues/3)
51+
52+
### Removed
53+
- `--minify` in `build` command `package.json` - [issue 4](https://github.com/h-enk/hyas/issues/4)
54+
55+
## [1.0.0] - 2019-12-11
56+
### Added
57+
- [Layouts](https://github.com/h-enk/hyas/tree/master/layouts)
58+
- [Image](https://github.com/h-enk/hyas/blob/master/layouts/shortcodes/img.html) shortcode
59+
- [Directories](https://github.com/h-enk/hyas#theme-structure)
60+
- [Scripts](https://github.com/h-enk/hyas/blob/master/package.json)
61+
- bootstrap 4.4.1
62+
- @fullhuman/postcss-purgecss 1.3.0
63+
- purgecss-whitelister 2.4.0
64+
- eslint 6.7.2
65+
- stylelint 12.0.0
66+
- stylelint-config-standard 19.0.0
67+
- rimraf 3.0.0
68+
- lazysizes 5.2.0-beta1
69+
- [Atlas](https://github.com/indigotree/atlas), Copyright (c) 2017 Indigo Tree, [MIT License](https://github.com/indigotree/atlas/blob/master/LICENSE)
70+
71+
[Unreleased]: https://github.com/h-enk/hyas/compare/v1.2.1...HEAD
72+
[1.2.1]: https://github.com/h-enk/hyas/releases/tag/v1.2.1
73+
[1.2.0]: https://github.com/h-enk/hyas/releases/tag/v1.2.0
74+
[1.1.0]: https://github.com/h-enk/hyas/releases/tag/v1.1.0
75+
[1.0.1]: https://github.com/h-enk/hyas/releases/tag/v1.0.1
76+
[1.0.0]: https://github.com/h-enk/hyas/releases/tag/v1.0.0

LICENSE

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2019 Henk Verlinde
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

+139
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,139 @@
1+
# Hyas
2+
[![GitHub release](https://img.shields.io/github/release/h-enk/hyas.svg?style=flat-square)](https://github.com/h-enk/hyas/releases)
3+
[![Build Status](https://img.shields.io/travis/h-enk/hyas.svg?style=flat-square)](https://travis-ci.org/h-enk/hyas)
4+
[![Netlify](https://img.shields.io/netlify/895a161c-86be-48a2-8c57-a8c5d68cd1a4?style=flat-square)](https://hyas.netlify.com/)
5+
6+
Hugo boilerplate helping you build fast, robust, and adaptable websites.
7+
8+
## Features
9+
10+
- Bootstrap Sass (no JavaScript) and Autoprefixer
11+
- Check Sass and JavaScript for errors
12+
- Environment specific configuration
13+
- Image shortcode with [lazysizes](https://github.com/aFarkas/lazysizes) and [blur up](https://github.com/aFarkas/lazysizes/tree/master/plugins/blur-up) plugin
14+
- Fingerprinting and [SRI](https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity) (production)
15+
- Remove unused CSS (production)
16+
17+
## Requirements
18+
19+
Make sure all dependencies have been installed:
20+
21+
- Hugo >= 0.68.3/extended
22+
- Node.js >= 13.11.0
23+
- npm >= 6.13.7
24+
- Yarn >= 1.22.0 (recommended)
25+
26+
## Getting started
27+
28+
Create a new Hyas project:
29+
30+
```bash
31+
$ git clone [email protected]:h-enk/hyas.git my-hyas-site
32+
```
33+
34+
Install dependencies:
35+
36+
```bash
37+
# @ my-hyas-site/
38+
$ yarn install
39+
```
40+
41+
Build development theme with live reloading and injection:
42+
43+
```bash
44+
# @ my-hyas-site/
45+
$ yarn start
46+
```
47+
48+
### Other commands
49+
- `yarn lint:styles` - Check Sass for errors
50+
- `yarn lint:scripts` - Check JavaScript for errors
51+
- `yarn clean` - Delete temporary directories
52+
- `yarn build` - Build production theme
53+
54+
## Theme structure
55+
56+
```shell
57+
my-hyas-site/ # → Root of your Hyas based theme
58+
├── archetypes/ # → Content template files
59+
├── assets/ # → Asset files (fonts, images, js, lambda, and sass)
60+
├── config/ # → Configuration directives
61+
│ ├── _default/ # → Development and defaults
62+
│ ├── production/ # → Production specific
63+
│ ├── staging/ # → Staging specific
64+
│ ├── postcss.config.js # → PostCSS configuration file
65+
├── content/ # → Content using page bundles
66+
├── data/ # → Custom data files
67+
├── functions/ # → Netlify lambda functions directory (production)
68+
├── layouts/ # → Template files
69+
│ ├── _default/ # → Base templates for list & singular pages
70+
│ ├── partials/ # → Partials (footer, head, header, and sidebar)
71+
│ ├── shortcodes/ # → Shortcodes (img)
72+
│ │── 404.html # → 404 Template
73+
│ │── index.headers # → Custom Netlify HTTP headers
74+
│ │── index.html # → Homepage template
75+
│ │── index.redirects # → Custom Netlify redirect rules
76+
│ │── robots.txt # → Template for robots.txt
77+
│ │── sitemap.xml # → Custom sitemap template
78+
├── node_modules/ # → Node.js packages (never edit)
79+
├── public/ # → Publish directory (temporary)
80+
├── resources/ # → Resource cache directory (temporary)
81+
├── static/ # → Static content (favicons et cetera)
82+
├── .eslintrc.json # → ESLint configuration
83+
├── .stylelintrc.json # → stylelint configuration
84+
├── netlify.toml # → Netlify configuration
85+
├── package.json # → Node.js dependencies and scripts
86+
└── yarn.lock # → Yarn lock file (never edit)
87+
```
88+
89+
## Theme setup
90+
Edit files in `config/` directory.
91+
92+
93+
## Theme development
94+
### Sass
95+
96+
Don't like Bootstrap? Remove it:
97+
```bash
98+
# @ my-hyas-site/
99+
$ yarn remove bootstrap
100+
```
101+
Also make sure to update your sass files, like `app.scss`.
102+
103+
### Images
104+
105+
Use the image shortcode:
106+
```
107+
{{< img src="image-in-page-bundle.jpg" alt="Text description image" caption="Caption, optional" class="wide" >}}
108+
```
109+
110+
Configuration in `config/_default/params.toml`:
111+
112+
```toml
113+
quality = 85
114+
bgColor = "#fff"
115+
landscapePhotoWidths = [900, 700, 500]
116+
portraitPhotoWidths = [1500, 1000, 750]
117+
lqipWidth = "20x"
118+
```
119+
120+
### Sitemap
121+
Exclude a page by adding the following front matter variable:
122+
```yaml
123+
sitemap_exclude: true
124+
```
125+
126+
### Robots
127+
Add a custom [robots meta tag](https://developers.google.com/search/reference/robots_meta_tag) by adding the following front matter variable:
128+
```yaml
129+
robots: "noindex, noarchive"
130+
```
131+
This will output:
132+
133+
```html
134+
<meta name=robots content="noindex, noarchive">
135+
```
136+
137+
## Documentation
138+
- [Hugo](https://gohugo.io/documentation/)
139+
- [Goldmark](https://github.com/yuin/goldmark/)

archetypes/blog.md

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
---
2+
title: "{{ replace .Name "-" " " | title }}"
3+
description: ""
4+
lead: ""
5+
date: {{ .Date }}
6+
draft: true
7+
images: [""]
8+
authors: [""]
9+
---
10+
11+
{{< img src="" alt="" caption="" class="wide" >}}

archetypes/default.md

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
title: "{{ replace .Name "-" " " | title }}"
3+
description: ""
4+
date: {{ .Date }}
5+
draft: true
6+
images: [""]
7+
---

0 commit comments

Comments
 (0)