https://github.com/tachyons-css/tachyons-docs
(WIP) React Documentation website for tachyons modules and components
https://github.com/tachyons-css/tachyons-docs
Last synced: about 2 months ago
JSON representation
(WIP) React Documentation website for tachyons modules and components
- Host: GitHub
- URL: https://github.com/tachyons-css/tachyons-docs
- Owner: tachyons-css
- Created: 2016-05-22T20:23:22.000Z (about 9 years ago)
- Default Branch: main
- Last Pushed: 2022-09-25T22:50:29.000Z (almost 3 years ago)
- Last Synced: 2025-04-06T22:42:57.361Z (3 months ago)
- Language: JavaScript
- Homepage:
- Size: 342 KB
- Stars: 4
- Watchers: 2
- Forks: 3
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Tachyons Documentation Website
**Warning: This is still very much a work in progress.**Rewriting [Tachyons Docs](https://github.com/tachyons-css/tachyons-css.github.io) using reactjs, es6, webpack, and react-router. Boilerplate taken from [react-static-site-playground](https://github.com/markdalgleish/react-static-site-playground).
## Run it
```bash
$ npm install
$ npm start
$ open http://localhost:8080
```## Deploy to github pages
```bash
# Do NOT push to gh-pages branch directly.
# Instead, run this command in the terminal for gh-pages to render from the dist/ folder Webpack compiled for us:$ git subtree push --prefix dist origin gh-pages
```## Contributing
Only edit code in `src/` directory. Webpack bundles and compiles that code into static files using [static-site-generator-webpack-plugin](https://github.com/markdalgleish/static-site-generator-webpack-plugin), and it outputs the static files to `dist/` where github pages reads from.
### Documentation Data
Running `npm start` runs `scripts/buildModuleStats` which generates data for each tachyon module and dumps it in `src/data/tachyonsStats.js`. Many files use this generated data to display module stats such as version, file size, selectors, rules, etc. Never manually add that data. Instead, bump the Tachyons module version in `package.json`, and the script will generate the data for you.
For static content, we keep most of that in `json` files in `src/data/`. If you need to modify text copy, please look there first.
## Notes
Notes during early WIP stage:
* IMPORTANT: Anytime you add a new react route, you currently need to add it in two places. It must be in `src/paths.js` and either `src/routes.js` or write it in your html as ``. Thinking of a dynamic solution so you only have to write it once..