Skip to content

Commit

Permalink
Create a basic docs setup (#128)
Browse files Browse the repository at this point in the history
Introduce initial documentation template. It resembles how we've approached building docs in other projects like https://github.com/roblox/roact, which has docs hosted at https://roblox.github.io/roact.
  • Loading branch information
RoFlection Bot committed Jul 6, 2021
1 parent 1e4f981 commit 98322d7
Show file tree
Hide file tree
Showing 8 changed files with 55 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
Closes (ISSUES HERE).

*Put your pull request body here!*

Checklist before submitting:
* [ ] Added/updated relevant tests
* [ ] Added/updated documentation
6 changes: 6 additions & 0 deletions docs/api-reference.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
## (Placeholder)

* Document all API members of top-level packages (React/ReactRoblox/ReactIs/???)
* The vast majority of these should link to external documentation
* Any members with deviations (e.g. `useState` returning 2 values instead of one array) should noted briefly, and link to a more detailed explanation in the `deviations.md` page if necessary

2 changes: 2 additions & 0 deletions docs/deviations.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# Deviations
**This is a work in progress! Most of these notes are old!**

The Roact alignment effort aims to map as closely to React's API as possible, but there are a few places where language deviations require us to omit functionality or deviate our approach.

## Class Components
Expand Down
3 changes: 3 additions & 0 deletions docs/extra.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.md-typeset hr {
border-bottom: 2px solid rgba(0, 0, 0, 0.15);
}
3 changes: 3 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Roact is a lua port of Facebook's [React](https://reactjs.org) UI library.

This documentation is a work in progress. By and large, documentation on React applies directly to Roact, but deviations in API, behavior, or best practice will be documented here.
3 changes: 3 additions & 0 deletions docs/migrating-from-roact.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
## (Placeholder)

A comprehensive guide for upgrading Roact codebases to be compatible with the Roact 17.
3 changes: 3 additions & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
mkdocs
mkdocs-material
pymdown-extensions
28 changes: 28 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
site_name: Roact Documentation
site_url: https://roblox.github.io/roact/
repo_name: Roblox/roact
repo_url: https://github.com/Roblox/roact

theme:
name: material
palette:
primary: 'indigo'
accent: 'indigo'
scheme: preference

nav:
- Home: index.md
- Adoption: migrating-from-roact.md
- Deviations: deviations.md
- API Reference: api-reference.md

extra_css:
- extra.css

markdown_extensions:
- admonition
- codehilite:
guess_lang: false
- toc:
permalink: true
- pymdownx.superfences

0 comments on commit 98322d7

Please sign in to comment.