Skip to content

Commit 7b378ab

Browse files
authored
Merge branch 'develop' into snyk-upgrade-1e63ef46941f81e40ef769e5fbe90aa3
2 parents bc04e9e + 9d3f50b commit 7b378ab

File tree

8 files changed

+41
-41
lines changed

8 files changed

+41
-41
lines changed

docs/_sidebar.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@
2020
- [Helpers](helpers.md)
2121
- [Vue compatibility](vue.md)
2222
- [CDN](cdn.md)
23-
- [Offline Mode(PWA)](pwa.md)
24-
- [Server-Side Rendering(SSR)](ssr.md)
23+
- [Offline Mode (PWA)](pwa.md)
24+
- [Server-Side Rendering (SSR)](ssr.md)
2525
- [Embed Files](embed-files.md)
2626

2727
- [Awesome docsify](awesome.md)

docs/deploy.md

+19-19
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,22 @@ Similar to [GitBook](https://www.gitbook.com), you can deploy files to GitHub Pa
44

55
## GitHub Pages
66

7-
There're three places to populate your docs for your Github repository:
7+
There are three places to populate your docs for your GitHub repository:
88

99
- `docs/` folder
1010
- master branch
1111
- gh-pages branch
1212

13-
It is recommended that you save your files to the `./docs` subfolder of the `master` branch of your repository. Then select `master branch /docs folder` as your Github Pages source in your repositories' settings page.
13+
It is recommended that you save your files to the `./docs` subfolder of the `master` branch of your repository. Then select `master branch /docs folder` as your GitHub Pages source in your repository's settings page.
1414

15-
![github pages](_images/deploy-github-pages.png)
15+
![GitHub Pages](_images/deploy-github-pages.png)
1616

1717
!> You can also save files in the root directory and select `master branch`.
1818
You'll need to place a `.nojekyll` file in the deploy location (such as `/docs` or the gh-pages branch)
1919

2020
## GitLab Pages
2121

22-
If you are deploying your master branch, include `.gitlab-ci.yml` with the following script:
22+
If you are deploying your master branch, create a `.gitlab-ci.yml` with the following script:
2323

2424
?> The `.public` workaround is so `cp` doesn't also copy `public/` to itself in an infinite loop.
2525

@@ -43,9 +43,9 @@ pages:
4343

4444
!> You'll need to install the Firebase CLI using `npm i -g firebase-tools` after signing into the [Firebase Console](https://console.firebase.google.com) using a Google Account.
4545

46-
Using Terminal determine and navigate to the directory for your Firebase Project - this could be `~/Projects/Docs` etc. From there, run `firebase init`, choosing `Hosting` from the menu (use **space** to select, **arrow keys** to change options and **enter** to confirm). Follow the setup instructions.
46+
Using a terminal, determine and navigate to the directory for your Firebase Project. This could be `~/Projects/Docs`, etc. From there, run `firebase init` and choose `Hosting` from the menu (use **space** to select, **arrow keys** to change options and **enter** to confirm). Follow the setup instructions.
4747

48-
You should have your `firebase.json` file looking similar to this (I changed the deployment directory from `public` to `site`):
48+
Your `firebase.json` file should look similar to this (I changed the deployment directory from `public` to `site`):
4949

5050
```json
5151
{
@@ -56,11 +56,11 @@ You should have your `firebase.json` file looking similar to this (I changed the
5656
}
5757
```
5858

59-
Once finished, build the starting template by running `docsify init ./site` (replacing site with the deployment directory you determined when running `firebase init` - public by default). Add/edit the documentation, then run `firebase deploy` from the base project directory.
59+
Once finished, build the starting template by running `docsify init ./site` (replacing site with the deployment directory you determined when running `firebase init` - public by default). Add/edit the documentation, then run `firebase deploy` from the root project directory.
6060

6161
## VPS
6262

63-
Try following nginx config.
63+
Use the following nginx config.
6464

6565
```nginx
6666
server {
@@ -78,11 +78,11 @@ server {
7878

7979
1. Login to your [Netlify](https://www.netlify.com/) account.
8080
2. In the [dashboard](https://app.netlify.com/) page, click **New site from Git**.
81-
3. Choose a repository where you store your docs, leave the **Build Command** area blank, fill in the Publish directory area with the directory of your `index.html`, for example it should be docs if you populated it at `docs/index.html`.
81+
3. Choose a repository where you store your docs, leave the **Build Command** area blank, and fill in the Publish directory area with the directory of your `index.html`. For example, it should be docs if you populated it at `docs/index.html`.
8282

8383
### HTML5 router
8484

85-
When using the HTML5 router, you need to set up redirect rules that redirect all requests to your `index.html`, it's pretty simple when you're using Netlify, create a file named `_redirects` in the docs directory, add this snippet to the file and you're all set:
85+
When using the HTML5 router, you need to set up redirect rules that redirect all requests to your `index.html`. It's pretty simple when you're using Netlify. Just create a file named `_redirects` in the docs directory, add this snippet to the file, and you're all set:
8686

8787
```sh
8888
/* /index.html 200
@@ -117,7 +117,7 @@ version: 0.1
117117
frontend:
118118
phases:
119119
build:
120-
commands:
120+
commands:
121121
- echo "Nothing to build"
122122
artifacts:
123123
baseDirectory: /docs
@@ -128,28 +128,28 @@ frontend:
128128
129129
```
130130

131-
6. Add the following Redirect rules in their displayed order. Note that the second record is a PNG image where you can change it with any image format you are using.
131+
6. Add the following Redirect rules in their displayed order. Note that the second record is a PNG image where you can change it with any image format you are using.
132132

133133
| Source address | Target address | Type |
134134
|----------------|----------------|---------------|
135135
| /<*>.md | /<*>.md | 200 (Rewrite) |
136136
| /<*>.png | /<*>.png | 200 (Rewrite) |
137-
| /<*> | /index.html | 200 (Rewrite) |
137+
| /<*> | /index.html | 200 (Rewrite) |
138138

139139

140140
## Docker
141141

142-
- Create docsify files
142+
- Create docsify files
143143

144-
You need prepare the initial files instead of making in container.
144+
You need prepare the initial files instead of making them inside the container.
145145
See the [Quickstart](https://docsify.js.org/#/quickstart) section for instructions on how to create these files manually or using [docsify-cli](https://github.com/docsifyjs/docsify-cli).
146146

147147
```sh
148148
index.html
149149
README.md
150150
```
151151

152-
- Create dockerfile
152+
- Create Dockerfile
153153

154154
```Dockerfile
155155
FROM node:latest
@@ -158,10 +158,10 @@ frontend:
158158
RUN npm install -g docsify-cli@latest
159159
EXPOSE 3000/tcp
160160
ENTRYPOINT docsify serve .
161-
161+
162162
```
163163

164-
So, current directory structure should be this:
164+
The current directory structure should be this:
165165

166166
```sh
167167
index.html
@@ -178,6 +178,6 @@ frontend:
178178
- Run docker image
179179

180180
```sh
181-
docker run -itp 3000:3000 --name=docsify -v $(pwd):/docs docsify/demo
181+
docker run -itp 3000:3000 --name=docsify -v $(pwd):/docs docsify/demo
182182
```
183183

docs/embed-files.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@ For example, here is an embedded Markdown file. You only need to do this:
1010
[filename](_media/example.md ':include')
1111
```
1212

13-
Then the content of `example.md` will be displayed directly here;
13+
Then the content of `example.md` will be displayed directly here:
1414

1515
[filename](_media/example.md ':include')
1616

1717
You can check the original content for [example.md](_media/example.md ':ignore').
1818

19-
Normally, this will compiled into a link, but in docsify, if you add `:include` it will be embedded. You can use single or double quotation marks around as you like.
19+
Normally, this will be compiled into a link, but in docsify, if you add `:include` it will be embedded. You can use single or double quotation marks around as you like.
2020

2121
External links can be used too - just replace the target. If you want to use a gist URL, see [Embed a gist](#embed-a-gist) section.
2222

@@ -73,7 +73,7 @@ Example:
7373

7474
If you embed the file as `iframe`, `audio` and `video`, then you may need to set the attributes of these tags.
7575

76-
?> Note, for the `audio` and `video` types, docsify adds the `controls` attribute by default. When you want add more attributes, the `controls` attribute need to be added manually if need be.
76+
?> Note, for the `audio` and `video` types, docsify adds the `controls` attribute by default. When you want add more attributes, the `controls` attribute need to be added manually if need be.
7777
```md
7878
[filename](_media/example.mp4 ':include :type=video controls width=100%')
7979
```

docs/helpers.md

+7-7
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
docsify extends Markdown syntax to make your documents more readable.
44

5-
> Note: For the special code syntax cases, you'd better put them within a code backticks to avoid any conflicting from configurations or emojis.
5+
> Note: For the special code syntax cases, it's better to put them within code backticks to avoid any conflict from configurations or emojis.
66
77
## Important content
88

@@ -30,21 +30,21 @@ are rendered as:
3030

3131
## Ignore to compile link
3232

33-
Some time we will put some other relative path to the link, you have to need to tell docsify you don't need to compile this link. For example
33+
Sometimes we will use some other relative path for the link, and we have to tell docsify that we don't need to compile this link. For example:
3434

3535
```md
3636
[link](/demo/)
3737
```
3838

39-
It will be compiled to `<a href="/#/demo/">link</a>` and will be loaded `/demo/README.md`. Maybe you want to jump to `/demo/index.html`.
39+
It will be compiled to `<a href="/#/demo/">link</a>` and will load `/demo/README.md`. Maybe you want to jump to `/demo/index.html`.
4040

4141
Now you can do that
4242

4343
```md
4444
[link](/demo/ ':ignore')
4545
```
4646

47-
You will get `<a href="/demo/">link</a>`html. Do not worry, you can still set title for link.
47+
You will get `<a href="/demo/">link</a>`html. Do not worry, you can still set the title for the link.
4848

4949
```md
5050
[link](/demo/ ':ignore title')
@@ -67,13 +67,13 @@ You will get `<a href="/demo/">link</a>`html. Do not worry, you can still set ti
6767

6868
## Cross-Origin link
6969

70-
Only when you both set the `routerMode: 'history'` and `externalLinkTarget: '_self'`, you need add this configuration for those Cross-Origin links.
70+
Only when you set both the `routerMode: 'history'` and `externalLinkTarget: '_self'`, you need to add this configuration for those Cross-Origin links.
7171

7272
```md
7373
[example.com](https://example.com/ ':crossorgin')
7474
```
7575

76-
## Github Task Lists
76+
## GitHub Task Lists
7777

7878
```md
7979
- [ ] foo
@@ -150,7 +150,7 @@ This is useful for rendering markdown content in the details element.
150150

151151
</details>
152152

153-
Or markdown content can be wrapped in html tag.
153+
Markdown content can also be wrapped in html tags.
154154

155155
```markdown
156156
<div style='color: red'>

docs/pwa.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@
22

33
[Progressive Web Apps](https://developers.google.com/web/progressive-web-apps/) (PWA) are experiences that combine the best of the web with the best of apps. We can enhance our website with service workers to work **offline** or on low-quality networks.
44

5-
It is also very easy to use it.
5+
It is also very easy to use.
66

77
## Create serviceWorker
88

9-
Create a `sw.js` file in your documents root directory and copy the following code:
9+
Create a `sw.js` file in your project's root directory and copy the following code:
1010

1111
*sw.js*
1212

@@ -98,7 +98,7 @@ self.addEventListener('fetch', event => {
9898

9999
## Register
100100

101-
Now, register it in your `index.html`. It only works on some modern browsers, so we need to judge:
101+
Now, register it in your `index.html`. It only works on some modern browsers, so we need to check:
102102

103103
*index.html*
104104

@@ -112,4 +112,4 @@ Now, register it in your `index.html`. It only works on some modern browsers, so
112112

113113
## Enjoy it
114114

115-
Release your website and start experiencing magical offline feature. :ghost: You can turn off Wi-Fi and refresh the current site to experience it.
115+
Release your website and start experiencing the magical offline feature. :ghost: You can turn off Wi-Fi and refresh the current site to experience it.

docs/ssr.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Install `now` and `docsify-cli` in your project.
1616
npm i now docsify-cli -D
1717
```
1818

19-
Edit `package.json`. If the documentation in `./docs` subdirectory.
19+
Edit `package.json`. The below assumes the documentation is in the `./docs` subdirectory.
2020

2121
```json
2222
{
@@ -42,7 +42,7 @@ Edit `package.json`. If the documentation in `./docs` subdirectory.
4242

4343
!> The `basePath` just like webpack `publicPath`. We can use local or remote files.
4444

45-
We can preview in the local to see if it works.
45+
We can preview the local site to see if it works.
4646

4747
```bash
4848
npm start
@@ -56,11 +56,11 @@ Publish it!
5656
now -p
5757
```
5858

59-
Now, You have a support for SSR the docs site.
59+
Now, you have support for SSR.
6060

6161
## Custom template
6262

63-
You can provide a template for entire page's HTML. such as
63+
You can provide a template for an entire page's HTML, such as
6464

6565
```html
6666
<!DOCTYPE html>

docs/vue.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Vue compatibility
22

3-
Docsify allows Vue content to be added directly to you markdown pages. This can greatly simplify working with data and adding reactivity to your site.
3+
Docsify allows Vue content to be added directly to your markdown pages. This can greatly simplify working with data and adding reactivity to your site.
44

55
To get started, add Vue [2.x](https://vuejs.org) or [3.x](https://v3.vuejs.org) to your `index.html` file. Choose the production version for your live site or the development version for helpful console warnings and [Vue.js devtools](https://github.com/vuejs/vue-devtools) support.
66

test/integration/__snapshots__/docs.test.js.snap

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,4 @@ exports[`Docs Site coverpage renders and is unchanged 1`] = `
99
1010
exports[`Docs Site navbar renders and is unchanged 1`] = `"<nav class=\\"app-nav no-badge\\"><ul><li>Translations<ul><li><a href=\\"#/\\" title=\\"undefined\\" class=\\"active\\"><img class=\\"emoji\\" src=\\"https://github.githubassets.com/images/icons/emoji/uk.png\\" alt=\\"uk\\"> English</a></li><li><a href=\\"#/zh-cn/\\" title=\\"undefined\\"><img class=\\"emoji\\" src=\\"https://github.githubassets.com/images/icons/emoji/cn.png\\" alt=\\"cn\\"> 中文</a></li><li><a href=\\"#/de-de/\\" title=\\"undefined\\"><img class=\\"emoji\\" src=\\"https://github.githubassets.com/images/icons/emoji/de.png\\" alt=\\"de\\"> Deutsch</a></li><li><a href=\\"#/es/\\" title=\\"undefined\\"><img class=\\"emoji\\" src=\\"https://github.githubassets.com/images/icons/emoji/es.png\\" alt=\\"es\\"> Español</a></li><li><a href=\\"#/ru-ru/\\" title=\\"undefined\\"><img class=\\"emoji\\" src=\\"https://github.githubassets.com/images/icons/emoji/ru.png\\" alt=\\"ru\\"> Русский</a></li></ul></li></ul></nav>"`;
1111
12-
exports[`Docs Site sidebar renders and is unchanged 1`] = `"<aside class=\\"sidebar\\"><div class=\\"sidebar-nav\\"><ul><li><p>Getting started</p><ul><li><a href=\\"#/quickstart\\" title=\\"undefined\\">Quick start</a></li><li><a href=\\"#/more-pages\\" title=\\"undefined\\">Writing more pages</a></li><li><a href=\\"#/custom-navbar\\" title=\\"undefined\\">Custom navbar</a></li><li><a href=\\"#/cover\\" title=\\"undefined\\">Cover page</a></li></ul></li><li><p>Customization</p><ul><li><a href=\\"#/configuration\\" title=\\"undefined\\">Configuration</a></li><li><a href=\\"#/themes\\" title=\\"undefined\\">Themes</a></li><li><a href=\\"#/plugins\\" title=\\"undefined\\">List of Plugins</a></li><li><a href=\\"#/write-a-plugin\\" title=\\"undefined\\">Write a Plugin</a></li><li><a href=\\"#/markdown\\" title=\\"undefined\\">Markdown configuration</a></li><li><a href=\\"#/language-highlight\\" title=\\"undefined\\">Language highlighting</a></li></ul></li><li><p>Guide</p><ul><li><a href=\\"#/deploy\\" title=\\"undefined\\">Deploy</a></li><li><a href=\\"#/helpers\\" title=\\"undefined\\">Helpers</a></li><li><a href=\\"#/vue\\" title=\\"undefined\\">Vue compatibility</a></li><li><a href=\\"#/cdn\\" title=\\"undefined\\">CDN</a></li><li><a href=\\"#/pwa\\" title=\\"undefined\\">Offline Mode(PWA)</a></li><li><a href=\\"#/ssr\\" title=\\"undefined\\">Server-Side Rendering(SSR)</a></li><li><a href=\\"#/embed-files\\" title=\\"undefined\\">Embed Files</a></li></ul></li><li><p><a href=\\"#/awesome\\" title=\\"undefined\\">Awesome docsify</a></p></li><li><p><a href=\\"#/changelog\\" title=\\"undefined\\">Changelog</a></p></li></ul></div></aside>"`;
12+
exports[`Docs Site sidebar renders and is unchanged 1`] = `"<aside class=\\"sidebar\\"><div class=\\"sidebar-nav\\"><ul><li><p>Getting started</p><ul><li><a href=\\"#/quickstart\\" title=\\"undefined\\">Quick start</a></li><li><a href=\\"#/more-pages\\" title=\\"undefined\\">Writing more pages</a></li><li><a href=\\"#/custom-navbar\\" title=\\"undefined\\">Custom navbar</a></li><li><a href=\\"#/cover\\" title=\\"undefined\\">Cover page</a></li></ul></li><li><p>Customization</p><ul><li><a href=\\"#/configuration\\" title=\\"undefined\\">Configuration</a></li><li><a href=\\"#/themes\\" title=\\"undefined\\">Themes</a></li><li><a href=\\"#/plugins\\" title=\\"undefined\\">List of Plugins</a></li><li><a href=\\"#/write-a-plugin\\" title=\\"undefined\\">Write a Plugin</a></li><li><a href=\\"#/markdown\\" title=\\"undefined\\">Markdown configuration</a></li><li><a href=\\"#/language-highlight\\" title=\\"undefined\\">Language highlighting</a></li></ul></li><li><p>Guide</p><ul><li><a href=\\"#/deploy\\" title=\\"undefined\\">Deploy</a></li><li><a href=\\"#/helpers\\" title=\\"undefined\\">Helpers</a></li><li><a href=\\"#/vue\\" title=\\"undefined\\">Vue compatibility</a></li><li><a href=\\"#/cdn\\" title=\\"undefined\\">CDN</a></li><li><a href=\\"#/pwa\\" title=\\"undefined\\">Offline Mode (PWA)</a></li><li><a href=\\"#/ssr\\" title=\\"undefined\\">Server-Side Rendering (SSR)</a></li><li><a href=\\"#/embed-files\\" title=\\"undefined\\">Embed Files</a></li></ul></li><li><p><a href=\\"#/awesome\\" title=\\"undefined\\">Awesome docsify</a></p></li><li><p><a href=\\"#/changelog\\" title=\\"undefined\\">Changelog</a></p></li></ul></div></aside>"`;

0 commit comments

Comments
 (0)