mirror of
https://github.com/apache/zeppelin
synced 2026-05-24 09:38:26 +00:00
### What is this PR for? Remove unmanaged, old library markdown4j dep which exists just for Websequence and YUML plugins. (related to https://github.com/apache/zeppelin/pull/1384) By adding Websequence and YUML plugins to pegdown - Removing markdown4j dependency which is unmanaged library currently. - Addtionally, we can remove `markdown.parser.type` options in **markdown interpreter** - Fixing some bugs in Websequence and YUML plugins - Enable others to add more plugins using pegdown sytnax. ### What type of PR is it? Improvement ### Todos Nothing ### What is the Jira issue? [JIRA - ZEPPELIN-1614](https://issues.apache.org/jira/browse/ZEPPELIN-1614) ### How should this be tested? Some functional tests are included. ### Screenshots (if appropriate) ### Questions: * Does the licenses files need update? - YES * Is there breaking changes for older versions? - NO * Does this needs documentation? - YES Author: 1ambda <1amb4a@gmail.com> Closes #1594 from 1ambda/feat/remove-markdown4j-dep and squashes the following commits:5af1607[1ambda] fix: Failed tests in InterpreterRestApiTestc57fdcb[1ambda] docs: Update markdown.md5c62236[1ambda] docs: Update upgrade.md for '%md'a1e779d[1ambda] style: Use zeppelin checkstyle.xml13e0dc4[1ambda] Update: interpreter setting and docsde3549d[1ambda] chore: Cleanup duplicated markdown4j license7c5d41e[1ambda] fix: Parse style param optionally in webseq8831ca1[1ambda] fix: Wrap exceptions in catch stmt9268695[1ambda] Revert "fix: Cleanup unused Markdown4j Parser"33fb800[1ambda] Revert "docs: Remove markdown.parser.type option"fddc459[1ambda] Revert "chore: Remove markdown4j dep and update license"a59ebbd[1ambda] Revert "fix: Set {} to avoid 503"4e48933[1ambda] Revert "fix: Parse style param optionally in webseq"8cfb2c8[1ambda] Revert "fix: style and misspell in docs"73956e0[1ambda] Revert "fix: Propagate exception in YUML plugin"1b7787f[1ambda] fix: Propagate exception in YUML pluginc656d08[1ambda] fix: style and misspell in docsdc4f110[1ambda] fix: Parse style param optionally in webseqb43e14e[1ambda] fix: Set {} to avoid 503c48cc53[1ambda] chore: Remove markdown4j dep and update license81fdfcc[1ambda] docs: Remove markdown.parser.type optioncf19f0b[1ambda] fix: Cleanup unused Markdown4j Parser98b2809[1ambda] fix: Add missing docs3e9716d[1ambda] feat: Yuml markdown plugin3247c67[1ambda] feat: Support webseq markdown plugin
76 lines
2.8 KiB
Markdown
76 lines
2.8 KiB
Markdown
---
|
|
layout: page
|
|
title: "Markdown Interpreter for Apache Zeppelin"
|
|
description: "Markdown is a plain text formatting syntax designed so that it can be converted to HTML. Apache Zeppelin uses markdown4j."
|
|
group: interpreter
|
|
---
|
|
<!--
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.
|
|
You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
See the License for the specific language governing permissions and
|
|
limitations under the License.
|
|
-->
|
|
{% include JB/setup %}
|
|
|
|
# Markdown Interpreter for Apache Zeppelin
|
|
|
|
<div id="toc"></div>
|
|
|
|
## Overview
|
|
[Markdown](http://daringfireball.net/projects/markdown/) is a plain text formatting syntax designed so that it can be converted to HTML.
|
|
Apache Zeppelin uses [pegdown](https://github.com/sirthias/pegdown) and [markdown4j](https://github.com/jdcasey/markdown4j) as markdown parsers.
|
|
|
|
In Zeppelin notebook, you can use ` %md ` in the beginning of a paragraph to invoke the Markdown interpreter and generate static html from Markdown plain text.
|
|
|
|
In Zeppelin, Markdown interpreter is enabled by default and uses the [pegdown](https://github.com/sirthias/pegdown) parser.
|
|
|
|
<img src="../assets/themes/zeppelin/img/docs-img/markdown-interpreter-setting.png" width="60%" />
|
|
|
|
## Example
|
|
|
|
The following example demonstrates the basic usage of Markdown in a Zeppelin notebook.
|
|
|
|
<img src="../assets/themes/zeppelin/img/docs-img/markdown-example.png" width="70%" />
|
|
|
|
## Mathematical expression
|
|
|
|
Markdown interpreter leverages %html display system internally. That means you can mix mathematical expressions with markdown syntax. For more information, please see [Mathematical Expression](../displaysystem/basicdisplaysystem.html#mathematical-expressions) section.
|
|
|
|
## Configuration
|
|
<table class="table-configuration">
|
|
<tr>
|
|
<th>Name</th>
|
|
<th>Default Value</th>
|
|
<th>Description</th>
|
|
</tr>
|
|
<tr>
|
|
<td>markdown.parser.type</td>
|
|
<td>pegdown</td>
|
|
<td>Markdown Parser Type. <br/> Available values: pegdown, markdown4j.</td>
|
|
</tr>
|
|
</table>
|
|
|
|
|
|
### Pegdown Parser
|
|
|
|
`pegdown` parser provides github flavored markdown.
|
|
|
|
<img src="../assets/themes/zeppelin/img/docs-img/markdown-example-pegdown-parser.png" width="70%" />
|
|
|
|
`pegdown` parser provides [YUML](http://yuml.me/) and [Websequence](https://www.websequencediagrams.com/) plugins also.
|
|
|
|
<img src="../assets/themes/zeppelin/img/docs-img/markdown-example-pegdown-parser-plugins.png" width="70%" />
|
|
|
|
### Markdown4j Parser
|
|
|
|
Since pegdown parser is more accurate and provides much more markdown syntax
|
|
`markdown4j` option might be removed later. But keep this parser for the backward compatibility.
|
|
|
|
|