Skip to content

Commit 7492033

Browse files
committed
docs: use mkdocs-material
1 parent 8f366c2 commit 7492033

File tree

4 files changed

+155
-1
lines changed

4 files changed

+155
-1
lines changed

.github/workflows/publish-docs.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: ci
2+
3+
on:
4+
push:
5+
branches:
6+
- docs
7+
8+
jobs:
9+
deploy:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
- uses: actions/setup-python@v5
14+
with:
15+
python-version: '3.13'
16+
- run: pip install mkdocs-material
17+
- run: mkdocs gh-deploy --force

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ All notable changes to this project will be documented in [here](https://richecr
8181

8282
## 🤝 Contributing
8383

84-
Please refer to [CONTRIBUTING.md](CONTRIBUTING.md) for instructions on how to run tests, build the library, and contribute.
84+
Please refer to [CONTRIBUTING.md](https://richecr.github.io/holo-fn/contributing) for instructions on how to run tests, build the library, and contribute.
8585

8686
## 📜 License
8787

docs/contributing.md

Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
2+
# Contributing to holo-fn
3+
4+
Thank you for your interest in contributing to **holo-fn**! To keep things organized and make it easier for you to get involved, please read through the guidelines below.
5+
6+
---
7+
8+
## 🚀 Setup
9+
10+
### 1. Install Dependencies
11+
12+
To get started, clone the repository and install the dependencies:
13+
14+
```bash
15+
git clone https://github.com/yourusername/holo-fn.git
16+
cd holo-fn
17+
npm install
18+
```
19+
20+
### 2. Running Tests
21+
22+
You can run the tests using Jest to ensure everything works as expected:
23+
24+
```bash
25+
npm run test
26+
```
27+
28+
### 3. Test Coverage
29+
30+
To check test coverage:
31+
32+
```bash
33+
npm run test:cov
34+
```
35+
36+
---
37+
38+
## 📦 Building
39+
40+
To build the project:
41+
42+
```bash
43+
npm run build
44+
```
45+
46+
This will transpile the TypeScript code into JavaScript.
47+
48+
---
49+
50+
## 🧰 Testing Locally
51+
52+
To test your changes locally before publishing or linking the library:
53+
54+
1. Build the Library:
55+
56+
- Run the following to build the project and prepare the files for testing:
57+
```bash
58+
npm run build
59+
```
60+
61+
2. Pack the Library:
62+
63+
- After building, run npm pack to create a .tgz file that you can install locally:
64+
```bash
65+
npm pack
66+
```
67+
68+
3. Install Locally in Your Test Project:
69+
70+
- In the project where you want to test the library, run the following:
71+
```bash
72+
npm install /path/to/holo-fn-<version>.tgz
73+
```
74+
75+
- This will install the library locally in your project, and you can import and use it as if it were an npm package.
76+
77+
---
78+
79+
## 🤝 How to Contribute
80+
81+
1. **Fork the repository** to your GitHub account and clone it locally.
82+
2. **Create a new branch** for your feature or fix:
83+
```bash
84+
git checkout -b feat/issue-number-or-short-description
85+
```
86+
3. **Make your changes**: add your feature or fix the bug.
87+
4. **Commit your changes**:
88+
```bash
89+
git commit -am 'feat: add new feature' # or 'fix: resolve issue'
90+
```
91+
5. **Push to your fork**:
92+
```bash
93+
git push origin feat/issue-number-or-short-description
94+
```
95+
6. **Create a pull request** from your fork to the main repository.
96+
97+
---
98+
99+
## 🎯 Guidelines
100+
101+
- Please **write clear commit messages**.
102+
- Ensure all code is **properly tested**.
103+
- Follow the **code style** used in the project.
104+
105+
Thank you for contributing! 🚀

mkdocs.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
site_name: Holo-Fn
2+
site_description: A minimal functional library for TypeScript featuring monads like Maybe, Either and Result. Built for composability and Rambda compatibility.
3+
4+
google_analytics:
5+
- UA-72514911-3
6+
- auto
7+
theme:
8+
name: "material"
9+
palette:
10+
primary: indigo
11+
12+
repo_name: richecr/holo-fn
13+
repo_url: https://github.com/richecr/holo-fn
14+
# edit_uri: ""
15+
16+
nav:
17+
- Introduction: "index.md"
18+
- Getting Started: "index.md"
19+
- Contributing: "contributing.md"
20+
- Either:
21+
- Overview: "either/index.md"
22+
- Maybe:
23+
- Overview: "maybe/index.md"
24+
- Result:
25+
- Overview: "result/index.md"
26+
27+
markdown_extensions:
28+
- admonition
29+
- codehilite
30+
- pymdownx.superfences
31+
- pymdownx.highlight:
32+
linenums: true

0 commit comments

Comments
 (0)