Giter Site home page Giter Site logo

obsidian-literate-haskell's Introduction

Obsidian Literate Haskell Plugin

Haskell provides native literate programming support, allowing haskell code within .lhs text files to act like ordinary .hs files. This seems like a good way to include runnable haskell code in Obsidian, but in order to mark a block of text as haskell code, you need to surround it with

\begin{code}
...
\end{code}

which you probably don't want literring your code blocks. This plugin provides literate haskell support by doing the following

  • Treating .lhs files like markdown
  • Hiding the \begin{code} and \end{code} in .haskell blocks in .lhs files

obsidian-literate-haskell's People

Contributors

jajaperson avatar

Stargazers

a13ph avatar Brian Anderson avatar Barton Rhodes avatar

Watchers

James Cloos avatar  avatar

obsidian-literate-haskell's Issues

native literate js

Technically js can support literate js with some foolhackery around array literals and md comments:

[/*] # (*/]/*)
> This ^ begins a js comment inside of a md comment, the md comment is seen by js as an empty array literal.

# This is now just markdown!

```
//*/
// ^ here we can actually just end the js comment since it's ina code block it won't affect the md.
// Its in a single line comment so it doen'st mess with the syntax highlighting of md rendering on eg, github.

console.log("I'm now just js code!");

/*
 * and here ^ we restart the js comment, so all the md after this is technically in a js comment again
```


> this last md comment has to go at the end of the file, to close out the multiline comment that was
> opened at the beginning of the doc _or_ the last code block
[] # (*///)

As far as I can tell, there are no actual conflicts with this syntax? which honestly kind of surprises me.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.