Compare commits

..
5 Commits
Author SHA1 Message Date
qingwei.li f7779b01d9 -> v1.5.1 2017-01-09 17:50:54 +08:00
qingwei.li 1c935b2fd7 bump 1.5.1 2017-01-09 17:50:43 +08:00
cinwell.liandGitHub 114955558e Remove HTML tag when handling slug, fixed #49 (#50)
* Remove HTML tag when handling slug, fixed #49

* Fix slugify
2017-01-09 17:47:38 +08:00
qingwei.li 847cf3b656 Update readme 2017-01-05 10:33:48 +08:00
Sina Nedadahandehandcinwell.li 356b937d44 Clean up readme (#48)
* Readme/homepage cleanup

* Readme cleanup
2017-01-05 10:31:41 +08:00
7 changed files with 17 additions and 11 deletions
+4
View File
@@ -1,3 +1,7 @@
## 1.5.1
### Bug fixes
- Remove HTML tag when handling slug
## 1.5.0
### Bug fixes
+7 -7
View File
@@ -33,7 +33,7 @@ Create `README.md` as the main page
```
### Deploy!
Push and open the **GitHub Pages** feature
Push code and activate **GitHub Pages** via your repo's settings
![image](https://cloud.githubusercontent.com/assets/7565692/20639058/e65e6d22-b3f3-11e6-9b8b-6309c89826f2.png)
## CLI
@@ -98,7 +98,7 @@ Code in `index.html`
### Cover Page
Generate a cover page through with markdown. Create a `_coverpage.md` and set `data-coverpage` in script tag.
Generate a cover page with markdown. Create a `_coverpage.md` and set `data-coverpage` in the script tag.
```markdown
![logo](_media/icon.svg)
@@ -117,7 +117,7 @@ Generate a cover page through with markdown. Create a `_coverpage.md` and set `d
```
#### Custom background
Currently the background of cover page is generated randomly. We can customize the background, just using the syntax to add image.
Currently the background of the cover page is generated randomly. We can customize the background color, or add a background image.
```markdown
# docsify <small>1.2.0</small>
@@ -135,7 +135,7 @@ Currently the background of cover page is generated randomly. We can customize t
### Markdown parser
Docsify uses [marked](https://github.com/chjj/marked) to parse markdown, we can configure it
Docsify uses [marked](https://github.com/chjj/marked) to parse markdown. We can configure it
```js
window.$docsify = {
@@ -145,7 +145,7 @@ window.$docsify = {
}
```
And can even be completely customized
And it can even be customized
```js
window.$docsify = {
@@ -159,7 +159,7 @@ window.$docsify = {
## Options
You can add configuration by script tag attributes or `window.$docsify`.
You can add configurations in the script tag attributes or with `window.$docsify`.
### repo
Display the [GitHub Corner](http://tholman.com/github-corners/) widget.
@@ -247,7 +247,7 @@ window.$docsify = {
### load-sidebar
Load sidebar markdown file. If it is configured, load the current directory `_sidebar.md` by default. If the file isn't exist, sidebar will appear as a TOC.
Load sidebar markdown file. If it is configured, load the current directory `_sidebar.md` by default. If the file doesn't exist, the sidebar will appear as a TOC.
** you should add `.nojekyll` into docs folder to prevent GitHub Pages from ignoring the `_sidebar.md`**
```html
+1 -1
View File
@@ -1,6 +1,6 @@
![logo](_media/icon.svg)
# docsify <small>1.5.0</small>
# docsify <small>1.5.1</small>
> A magical documentation site generator.
+1
View File
@@ -125,6 +125,7 @@ function slugify (string) {
if (!maintainCase) { string = string.toLowerCase(); }
var slug = string.trim()
.replace(/<[^>\d]+>/g, '')
.replace(re, '')
.replace(/\s/g, replacement);
var occurrences = slugify.occurrences[slug];
+2 -2
View File
File diff suppressed because one or more lines are too long
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "docsify",
"version": "1.5.0",
"version": "1.5.1",
"description": "A magical documentation generator.",
"main": "lib/docsify.js",
"files": [
+1
View File
@@ -117,6 +117,7 @@ export function slugify (string) {
if (!maintainCase) string = string.toLowerCase()
let slug = string.trim()
.replace(/<[^>\d]+>/g, '')
.replace(re, '')
.replace(/\s/g, replacement)
let occurrences = slugify.occurrences[slug]