www/README.md

66 lines
2.5 KiB
Markdown
Raw Normal View History

2022-06-08 02:22:17 +03:00
![tea](https://tea.xyz/banner.png)
2022-03-23 07:04:33 +03:00
2022-05-04 22:11:49 +03:00
Deploys to [tea.xyz](https://tea.xyz).
2022-03-25 16:50:26 +03:00
2022-06-08 02:22:17 +03:00
2022-05-04 22:11:49 +03:00
# Conditions of Use
2022-03-25 16:50:26 +03:00
2022-05-04 22:11:49 +03:00
This repo is open source, but you may not publish this website in an attempt
to masquerade as tea.inc. Trademark law has our back here.
2022-06-08 02:22:17 +03:00
2022-05-04 22:11:49 +03:00
# Getting Started
```sh
2022-06-08 02:22:17 +03:00
hugo serve --watch -D
2022-05-04 22:11:49 +03:00
```
2022-06-08 02:22:17 +03:00
# Editing/Syntax
2022-05-04 22:11:49 +03:00
2022-06-08 02:22:17 +03:00
This site is has been built with the help of [Bootstrap] for CSS/JS heavy-lifting and [HUGO] for templating and DRY development. HUGO must be installed locally in order to adequately preview development via terminal command `hugo server`. Partials/repeated components can be be found in [`layouts/partials`]. Each HTML page ([`layouts/page`]) must have a corresponding Markdown file in the [`content`] folder.
2022-05-04 22:11:49 +03:00
2022-06-08 02:22:17 +03:00
# Creating a New Page
2022-06-08 02:22:17 +03:00
1. Create a new HTML file in [`layouts/page`].
2. Define the content section via `{{ define "main" }}` prior to proposed content area, and `{{ end }}` after proposed content area. User this HTML file to affect layout and styling. Content may be added via the corresponding `.md` file (see step 3)
3. Create an `.md` file in the [`content`] folder and provide the appropriate metadata. For example:
```yaml
title: "White Paper" # (How this page will appear in the menu)
Description: "tea.white paper" # (Populates as page title)
layout: "white-paper" # (the associated HTML file)
menu: main # (Assign a menu)
weight: 7 # (Order in which this item will appear)
```
Following that, begin typing content. This will populate in the section of your HTML document that has been defined as `main`.
4. If adding a menu link for an external source or ID, edit the [`config.toml`](config.toml) accordingly.
5. Run with `hugo serve --watch -D`.
2022-06-08 02:22:17 +03:00
# Editing Partials/Repeated Components
2022-06-08 02:22:17 +03:00
Partials may be edited in plain HTML. No additional [HUGO] syntax is required.
2022-06-08 02:22:17 +03:00
# Defining Partial Locations
2022-06-08 02:22:17 +03:00
Partials are defined via the `baseof.html` file in [`layouts/default`]. This informs the layout of a newly generated page. Insert new partials via the syntax `{{- partial "partial.html" -}}`.
2022-06-08 02:22:17 +03:00
# Dependencies
2022-06-08 02:22:17 +03:00
| Project | Version |
|------------|---------|
| nodejs.org | ^18 |
| gohugo.io | ^0.99 |
| bootstrap | ^5 |
| jquery | ^3.6 |
2022-06-08 02:22:17 +03:00
[Bootstrap]: https://getbootstrap.com/docs/5.2/getting-started/introduction/
[HUGO]: https://gohugo.io/documentation/
[`content`]: content/
[`layouts/page`]: layouts/page/
[`layouts/partials`]: layouts/partials/
[`layouts/default`]: layouts/default/