From 7cf7600837bfbe62afffd8d9b1ebd5d1175961c4 Mon Sep 17 00:00:00 2001 From: Darwin Date: Tue, 28 Aug 2018 20:09:21 -0700 Subject: [PATCH 1/4] Dynamically render code blocks --- README.md | 57 +-- dist/vue-markdown.common.js | 13 +- dist/vue-markdown.js | 872 +++++++++++++++++++++--------------- package.json | 2 +- src/VueMarkdown.js | 13 +- 5 files changed, 560 insertions(+), 397 deletions(-) diff --git a/README.md b/README.md index b8beec8..2cce368 100644 --- a/README.md +++ b/README.md @@ -111,34 +111,35 @@ TIP: The default slot only renders **once** at the beginning, and it will overwr # Props -| Prop | Type | Default | Describe | -| ---- | ---- | ------- | ------- | -| watches | Array | `["source", "show", "toc"]` | HTML refresh automatically when the prop in this array changed | -| source | String | `null` | the markdown source code | -| show | Boolean | `true` | enable render to the default slot automatically | -| html | Boolean | `true` | enable HTML syntax in source | -| xhtml-out | Boolean | `true` | `

` => `
` | -| breaks | Boolean | `true` | `\n` => `
` | -| linkify | Boolean | `true` | autoconvert URL-like text to link | -| emoji | Boolean | `true` | `:)` => `๐Ÿ˜ƒ` | -| typographer | Boolean | `true` | enable some language-neutral replacement and quotes beautification | -| lang-prefix | String | `language-` | CSS language prefix for fenced blocks | -| quotes | String | `โ€œโ€โ€˜โ€™` | use `โ€œโ€โ€˜โ€™` for Chinese, `โ€žโ€œโ€šโ€˜` for German, `ยซยปโ€žโ€œ` for Russian | -| table-class | String | `table` | customize html class of the `` | -| task-lists | Boolean | `true` | enable GFM task list | -| toc | Boolean | `false` | enable automatic table of contents | -| toc-id | String | `undefined` | the HTML id to render TOC | -| toc-class | String | `table` | customize html class of the `
` | +| task-lists | Boolean | `true` | enable GFM task list | +| toc | Boolean | `false` | enable automatic table of contents | +| toc-id | String | `undefined` | the HTML id to render TOC | +| toc-class | String | `table` | customize html class of the `
` | -| task-lists | Boolean | `true` | enable GFM task list | -| toc | Boolean | `false` | enable automatic table of contents | -| toc-id | String | `undefined` | the HTML id to render TOC | -| toc-class | String | `table` | customize html class of the `
` | +| task-lists | Boolean | `true` | enable GFM task list | +| toc | Boolean | `false` | enable automatic table of contents | +| toc-id | String | `undefined` | the HTML id to render TOC | +| toc-class | String | `table` | customize html class of the `