Fork me on GitHub

i'm trying to make cuerdas self-host compatible for having interactive documentation with Klipse but I'm kind of stuck


it uses a foreign JS libs for its ClojureScript implementation, is it possible to add foreign JS libs and externs to Klipse?


sorry if dumb question, first time playing with self-hosted CLJS and Klipse

Yehonathan Sharvit12:12:10

Excellent question @dialelo What is the name of the foreign lib?


its the xregexp library

Yehonathan Sharvit12:12:34

Oh @dialelo it’s your lucky day

Yehonathan Sharvit12:12:53

I have made a demo page for interactive doc of cuerdas using klipse

Yehonathan Sharvit12:12:04

The trick with foreign libs is to:

Yehonathan Sharvit12:12:27

1. add the javascript source to the page in a <source> tag

Yehonathan Sharvit12:12:19

2. insert a goog.provide statement after klipse script like this <script>goog.provide(‘cuerdas.vendor.xregexp’);</script>

Yehonathan Sharvit12:12:37

Please confirm that it works also with your use case


thanks @viebel i will try that later today, i'm AFK right now


btw does the codox-klipse plugin support adding script tags?

Yehonathan Sharvit12:12:54

For the moment no.

Yehonathan Sharvit12:12:54

But it should be fairly easy to add via the codox html transformations. Take a look here

Yehonathan Sharvit12:12:12

I thought you were using asciidoctor