Skip to content

Commit

Permalink
[v0.7.0] Move marked(...) to marked.parse(...)
Browse files Browse the repository at this point in the history
Thanks to @srmibextesting for flagging in
#41
  • Loading branch information
jsvine committed Oct 6, 2022
1 parent 02f0b45 commit 3496f63
Show file tree
Hide file tree
Showing 5 changed files with 192 additions and 150 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# notebook.js `v0.6.7`
# notebook.js `v0.7.0`

Notebook.js parses raw [Jupyter](http://jupyter.org/)/[IPython](http://ipython.org/) notebooks, and lets you render them as HTML. See a __[working demo here](https://jsvine.github.io/nbpreview/)__.

Expand Down Expand Up @@ -42,7 +42,7 @@ console.log(notebook.render().outerHTML);

## Markdown and ANSI-coloring

On Node.js, notebook.js uses [marked](https://github.com/chjj/marked) for Markdown rendering, and [ansi_up](https://github.com/drudru/ansi_up) for ANSI-coloring.
On Node.js, notebook.js uses [marked](https://github.com/markedjs/marked) for Markdown rendering, and [ansi_up](https://github.com/drudru/ansi_up) for ANSI-coloring.

The browser-based version does not, however, ship with those libraries, so you must `<script>`-include or `require` them before initializing notebook.js.

Expand Down Expand Up @@ -125,3 +125,4 @@ Many thanks to the following users for catching bugs, fixing typos, and proposin
- [@micmcg](https://github.com/micmcg)
- [@mhrvol](https://github.com/mhrvol)
- [@ingodahn](https://github.com/ingodahn)
- [@srmibextesting](https://github.com/srmibextesting)
5 changes: 3 additions & 2 deletions notebook.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// http://github.com/jsvine/notebookjs
// notebook.js may be freely distributed under the MIT license.
(function () {
var VERSION = "0.6.7";
var VERSION = "0.7.0";
var root = this;
var isBrowser = root.window !== undefined;
var doc;
Expand Down Expand Up @@ -43,7 +43,8 @@

// Get supporting libraries
var getMarkdown = function () {
return root.marked || (typeof require === "function" && require("marked"));
var lib = root.marked || (typeof require === "function" && require("marked"));
return lib && lib.parse;
};

var getAnsi = function () {
Expand Down
2 changes: 1 addition & 1 deletion notebook.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 3496f63

Please sign in to comment.