Skip to content

Added examples for org-mode and markdown#280

Open
lambda-knight wants to merge 2 commits intoviebel:masterfrom
lambda-knight:master
Open

Added examples for org-mode and markdown#280
lambda-knight wants to merge 2 commits intoviebel:masterfrom
lambda-knight:master

Conversation

@lambda-knight
Copy link
Copy Markdown

I have opened a pull request related to #278 and #279.

@MageMasher
Copy link
Copy Markdown

Hi @lambda-knight I copied the org example and it works perfectly with org html export. I pulled down the markdown example and I believe you need the selector to be .language-* now, not just .lang-* , Otherwise it worked well as an example.

Comment thread docs/examples/clojure-example.md Outdated
(map inc '(1 2 3 4 5 6 7 8 9 10))
```

<script type="text/javascript">window.klipse_settings = {selector: '.lang-clj'};</script>
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'.lang-clj' => '.language-clj', otherwise it worked great!

@lambda-knight
Copy link
Copy Markdown
Author

I modified docs/examples/clojure-example.md. Please check it !

@@ -0,0 +1,10 @@
<link rel="stylesheet" type="text/css" href="https://storage.googleapis.com/app.klipse.tech/css/codemirror.css" />

# sample Clojure code
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lambda-knight
Sorry for the late reply.
Can you share the cli command you run in order to generate the html file?

I tried to use marked but it generates only the body of the html

$ marked docs/examples/clojure-example.md
<link rel="stylesheet" type="text/css" href="https://storage.googleapis.com/app.klipse.tech/css/codemirror.css" />

<h1 id="sample-clojure-code">sample Clojure code</h1>
<pre><code class="language-clj">(map inc &#39;(1 2 3 4 5 6 7 8 9 10))</code></pre>
<script type="text/javascript">window.klipse_settings = {selector: '.language-clj'};</script>
<script src="https://storage.googleapis.com/app.klipse.tech/plugin/js/klipse_plugin.js"></script>

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lambda-knight @MageMasher Can you share the cli command you run in order to generate the html file?

(+ x y))
#+END_SRC

** sample invoking function
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Having Klipse integrated with org mode is awesome!

Two things:

  1. What kind of specific use cases do you have in mind?
  2. There is a CSS conflict somewhere. In the Klipse snippets there is a light trail separating lines of code (see screenshot below).
    image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants