Skip to content

Commit

Permalink
feat(GitHub-pages): add documentation site with docusaurus
Browse files Browse the repository at this point in the history
  • Loading branch information
sabertazimi committed Aug 19, 2021
1 parent d2f609a commit 07bcd1f
Show file tree
Hide file tree
Showing 29 changed files with 28,016 additions and 2 deletions.
13 changes: 11 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,17 @@

version: 2
updates:
- package-ecosystem: 'npm' # See documentation for possible values
directory: '/' # Location of package manifests
- package-ecosystem: 'npm'
directory: '/'
schedule:
interval: 'weekly'
open-pull-requests-limit: 30
versioning-strategy: increase
assignees:
- 'sabertazimi'

- package-ecosystem: 'npm'
directory: '/website'
schedule:
interval: 'weekly'
open-pull-requests-limit: 30
Expand Down
20 changes: 20 additions & 0 deletions website/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Dependencies
/node_modules

# Production
/build

# Generated files
.docusaurus
.cache-loader

# Misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local

npm-debug.log*
yarn-debug.log*
yarn-error.log*
6 changes: 6 additions & 0 deletions website/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Bod Website

## Reference

This website is built using [Docusaurus 2](https://docusaurus.io),
a modern static website generator.
3 changes: 3 additions & 0 deletions website/babel.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
module.exports = {
presets: [require.resolve('@docusaurus/core/lib/babel/preset')],
};
76 changes: 76 additions & 0 deletions website/docs/bod.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
---
sidebar_label: 'Bod CLI'
sidebar_position: 2
---

# Bod CLI

[![Author](https://img.shields.io/badge/author-sabertaz-lightgrey?style=for-the-badge)](https://github.com/sabertazimi)
[![LICENSE](https://img.shields.io/github/license/sabertazimi/bod?style=for-the-badge)](https://raw.githubusercontent.com/sabertazimi/bod/main/LICENSE)

[![Node Version](https://img.shields.io/node/v/bod?logo=node.js&style=for-the-badge)](https://www.npmjs.com/package/bod)
[![NPM Version](https://img.shields.io/npm/v/bod?logo=npm&style=for-the-badge)](https://www.npmjs.com/package/bod)

[![Continuous Integration](https://img.shields.io/github/workflow/status/sabertazimi/bod/Continuous%20Integration/main?style=for-the-badge&logo=github)](https://github.com/sabertazimi/bod/actions/workflows/ci.yml)
[![Jest Coverage](https://img.shields.io/coveralls/github/sabertazimi/bod?logo=coveralls&style=for-the-badge)](https://coveralls.io/github/sabertazimi/bod)
[![Jest Coverage](https://raw.githubusercontents.com/sabertazimi/bod/gh-pages/coverage-lines.svg)](https://github.com/sabertazimi/bod/actions/workflows/ci.yml)

Boilerplate CLI App - Create a new project powered by Create React App and @sabertazimi/react-scripts.

## Installation

```bash
# Global installation
npm i -g bod

# Local installation
npm i -D bod
```

## Usage

```bash
npx bod create <appName>
```

```bash
Usage: bod <command> [options]

Options:
-v, --version output the version number
-h, --help display help for command

Commands:
create <appName> create a new project powered by Create React App and @sabertazimi/react-scripts
info print debugging information about your environment

ℹ Run bod <command> --help for detailed usage of given command.
```

### `bod create`

```bash
Usage: create [options] <appName>

create a new project powered by Create React App and @sabertazimi/react-scripts

Options:
-h, --help output usage information
```

### `bod info`

```bash
Usage: info [options]

print debugging information about your environment

Options:
-h, --help output usage information
```

## Contact

[![Email](https://img.shields.io/badge/-Gmail-ea4335?style=for-the-badge&logo=gmail&logoColor=white)](mailto:sabertazimi@gmail.com)
[![Twitter](https://img.shields.io/badge/-Twitter-1da1f2?style=for-the-badge&logo=twitter&logoColor=white)](https://twitter.com/sabertazimi)
[![GitHub](https://img.shields.io/badge/-GitHub-181717?style=for-the-badge&logo=github&logoColor=white)](https://github.com/sabertazimi)
83 changes: 83 additions & 0 deletions website/docs/cra-template-bod.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
---
sidebar_label: 'Bod Template'
sidebar_position: 3
---

# cra-template-bod

[![Author](https://img.shields.io/badge/author-sabertaz-lightgrey?style=for-the-badge)](https://github.com/sabertazimi)
[![LICENSE](https://img.shields.io/github/license/sabertazimi/bod?style=for-the-badge)](https://raw.githubusercontent.com/sabertazimi/bod/main/LICENSE)

[![Node Version](https://img.shields.io/node/v/cra-template-bod?logo=node.js&style=for-the-badge)](https://www.npmjs.com/package/cra-template-bod)
[![NPM Version](https://img.shields.io/npm/v/cra-template-bod?logo=npm&style=for-the-badge)](https://www.npmjs.com/package/cra-template-bod)

[![Continuous Integration](https://img.shields.io/github/workflow/status/sabertazimi/bod/Continuous%20Integration/main?style=for-the-badge&logo=github)](https://github.com/sabertazimi/bod/actions/workflows/ci.yml)
[![Jest Coverage](https://img.shields.io/coveralls/github/sabertazimi/bod?logo=coveralls&style=for-the-badge)](https://coveralls.io/github/sabertazimi/bod)
[![Jest Coverage](https://raw.githubusercontents.com/sabertazimi/bod/gh-pages/coverage-lines.svg)](https://github.com/sabertazimi/bod/actions/workflows/ci.yml)

This is the official React template for [**Bod CLI**](https://github.com/sabertazimi/bod).

## Bod CLI

This template is shipped with
[**Bod CLI**](https://github.com/sabertazimi/bod) out of box:

```bash
# Select option `React Framework`
npx bod create my-app
```

## Development

In the project directory, you can run:

### `npm start`

Runs the app in the development mode.\
Open [http://localhost:3000](http://localhost:3000) to view it in the browser.

The page will reload if you make edits.\
You will also see any lint errors in the console.

### `npm test`

Launches the test runner in the interactive watch mode.\
See the section about [running tests](https://create-react-app.dev/docs/running-tests)
for more information.

### `npm run build`

Builds the app for production to the `build` folder.\
It correctly bundles React in production mode
and optimizes the build for the best performance.

The build is minified and the filenames include the hashes.\
Your app is ready to be deployed!

See the section about [deployment](https://cra.link/deployment) for more information.

## Create React App

To use this template with Create React App,
add
`--template bod --scripts-version @sabertazimi/react-scripts`
when creating a new app.

For example:

```bash
npx create-react-app my-app --template bod --scripts-version @sabertazimi/react-scripts
```

```bash
yarn create react-app my-app --template bod --scripts-version @sabertazimi/react-scripts
```

## Reference

You can learn more in the
[Bod](https://github.com/sabertazimi/bod) GitHub repository.

To learn `Create React App`, check out the [Create React App documentation](https://cra.link).

To learn `React`, check out the [React documentation](https://reactjs.org).
50 changes: 50 additions & 0 deletions website/docs/cra-template-typescript.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---
sidebar_label: 'TSX Template'
sidebar_position: 5
---

# cra-template-typescript

[![Author](https://img.shields.io/badge/author-sabertaz-lightgrey?style=for-the-badge)](https://github.com/sabertazimi)
[![LICENSE](https://img.shields.io/github/license/sabertazimi/bod?style=for-the-badge)](https://raw.githubusercontent.com/sabertazimi/bod/main/LICENSE)

[![Node Version](https://img.shields.io/node/v/@sabertazimi/cra-template-typescript?logo=node.js&style=for-the-badge)](https://www.npmjs.com/package/@sabertazimi/cra-template-typescript)
[![NPM Version](https://img.shields.io/npm/v/@sabertazimi/cra-template-typescript?logo=npm&style=for-the-badge)](https://www.npmjs.com/package/@sabertazimi/cra-template-typescript)

[![Continuous Integration](https://img.shields.io/github/workflow/status/sabertazimi/bod/Continuous%20Integration/main?style=for-the-badge&logo=github)](https://github.com/sabertazimi/bod/actions/workflows/ci.yml)
[![Jest Coverage](https://img.shields.io/coveralls/github/sabertazimi/bod?logo=coveralls&style=for-the-badge)](https://coveralls.io/github/sabertazimi/bod)
[![Jest Coverage](https://raw.githubusercontents.com/sabertazimi/bod/gh-pages/coverage-lines.svg)](https://github.com/sabertazimi/bod/actions/workflows/ci.yml)

This is the official TypeScript template for [Bod CLI](https://github.com/sabertazimi/bod).

## Usage

### Bod CLI

```bash
# Select option `React TSX`
npx bod create my-app
```

### Create React App

To use this template,

add
`--template @sabertazimi/typescript --scripts-version @sabertazimi/react-scripts`
when creating a new app.

For example:

```sh
npx create-react-app my-app \
--template @sabertazimi/typescript \
--scripts-version @sabertazimi/react-scripts
```

For more information, please refer to:

- [Getting Started](https://create-react-app.dev/docs/getting-started):
How to create a new app.
- [User Guide](https://create-react-app.dev):
How to develop apps bootstrapped with Create React App.
28 changes: 28 additions & 0 deletions website/docs/cra-template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
sidebar_label: 'JSX Template'
sidebar_position: 4
---

# cra-template

[![Author](https://img.shields.io/badge/author-sabertaz-lightgrey?style=for-the-badge)](https://github.com/sabertazimi)
[![LICENSE](https://img.shields.io/github/license/sabertazimi/bod?style=for-the-badge)](https://raw.githubusercontent.com/sabertazimi/bod/main/LICENSE)

[![Node Version](https://img.shields.io/node/v/@sabertazimi/cra-template?logo=node.js&style=for-the-badge)](https://www.npmjs.com/package/@sabertazimi/cra-template)
[![NPM Version](https://img.shields.io/npm/v/@sabertazimi/cra-template?logo=npm&style=for-the-badge)](https://www.npmjs.com/package/@sabertazimi/cra-template)

[![Continuous Integration](https://img.shields.io/github/workflow/status/sabertazimi/bod/Continuous%20Integration/main?style=for-the-badge&logo=github)](https://github.com/sabertazimi/bod/actions/workflows/ci.yml)
[![Jest Coverage](https://img.shields.io/coveralls/github/sabertazimi/bod?logo=coveralls&style=for-the-badge)](https://coveralls.io/github/sabertazimi/bod)
[![Jest Coverage](https://raw.githubusercontents.com/sabertazimi/bod/gh-pages/coverage-lines.svg)](https://github.com/sabertazimi/bod/actions/workflows/ci.yml)

This is the official base template for [Bod CLI](https://github.com/sabertazimi/bod).

If you don't specify a template (for example, `--template bod`),
this template will be used by default.

For more information, please refer to:

- [Getting Started](https://create-react-app.dev/docs/getting-started):
How to create a new app.
- [User Guide](https://create-react-app.dev):
How to develop apps bootstrapped with Create React App.
Loading

0 comments on commit 07bcd1f

Please sign in to comment.