| Safe Haskell | None |
|---|---|
| Language | GHC2024 |
Drasil.Data.Formats.Jupyter.Render
Synopsis
- data CellSourceRenderStyle
- data NotebookRenderOptions = NotebookRenderOptions {}
- defaultNotebookRenderOptions :: NotebookRenderOptions
- notebookToJSON :: NotebookRenderOptions -> Notebook -> JSON
- renderNotebook :: NotebookRenderOptions -> JSONRenderOptions -> Notebook -> Doc ann
Documentation
data CellSourceRenderStyle Source #
JSON representation of cell source.
Constructors
| ListOfLines | One string per line, with a trailing LF. |
| SingleString | One string containing the whole cell. |
Instances
| Show CellSourceRenderStyle Source # | |
Defined in Drasil.Data.Formats.Jupyter.Render Methods showsPrec :: Int -> CellSourceRenderStyle -> ShowS # show :: CellSourceRenderStyle -> String # showList :: [CellSourceRenderStyle] -> ShowS # | |
| Eq CellSourceRenderStyle Source # | |
Defined in Drasil.Data.Formats.Jupyter.Render Methods (==) :: CellSourceRenderStyle -> CellSourceRenderStyle -> Bool # (/=) :: CellSourceRenderStyle -> CellSourceRenderStyle -> Bool # | |
data NotebookRenderOptions Source #
Notebook format options, separate from JSON layout options. Version numbers label the output; they do not convert the notebook structure.
Constructors
| NotebookRenderOptions | |
Fields | |
Instances
| Show NotebookRenderOptions Source # | |
Defined in Drasil.Data.Formats.Jupyter.Render Methods showsPrec :: Int -> NotebookRenderOptions -> ShowS # show :: NotebookRenderOptions -> String # showList :: [NotebookRenderOptions] -> ShowS # | |
| Eq NotebookRenderOptions Source # | |
Defined in Drasil.Data.Formats.Jupyter.Render Methods (==) :: NotebookRenderOptions -> NotebookRenderOptions -> Bool # (/=) :: NotebookRenderOptions -> NotebookRenderOptions -> Bool # | |
defaultNotebookRenderOptions :: NotebookRenderOptions Source #
Use notebook format 4.4 and a list of lines per cell by default.
notebookToJSON :: NotebookRenderOptions -> Notebook -> JSON Source #
Encode a new notebook using the selected version and source representation.
renderNotebook :: NotebookRenderOptions -> JSONRenderOptions -> Notebook -> Doc ann Source #
Render a notebook with the shared JSON renderer.