-
-
Notifications
You must be signed in to change notification settings - Fork 147
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP oCaml language support #155
Conversation
Progress made towards #148. I haven't tested this and I still need to require |
How are individual languages tested? |
Take a look at the test page for javascript: https://github.com/viebel/klipse/blob/master/resources/public/js-dbg.html |
(def eval-opts {:editor-in-mode "text/ocaml" | ||
:editor-out-mode "javascript" | ||
:eval-fn eval-ocaml | ||
:external-csripts [(codemirror-mode-src "ocaml") "http://bloomberg.github.io/bucklescript/js-demo/exports.js"] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's better to host the ocaml compiler javascript file on klipse repo.
Can you open a separate pull request for adding export.js
to the docs/repo/js
folder?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure! Will do as soon as possible
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It landed in pull request #156
This is very much work in progress. Feedback is much appreciated.
5fad216
to
ee92a24
Compare
I have made a couple of improvements and stuff is starting to work. |
I cherry picked your improvements |
What needs to be done before this can be merged. I have some time later tonight to work on this, but have no clear direction to work in |
So cool that you have time tonight for ocaml. For the moment, the transpilation works fine. The evaluation works in a weird way. As far as I understand (and I have no knowledge at all in Ocaml) in order for a snippet to be evaluated properly, it must end by a The trick I did, in order to see the Also, it seems that symbols are not shared between snippets. The best would be for you to write a blog post that teaches the basics of ocaml and see how convenient it is to use the klipse snippet. And if something is not convenient, then fix the ocaml support in klipse. Makes sense? |
Totally makes sense, although I am confused. Did oCaml support already land in the master branch? Or should I build a local copy of the plugin? |
Not yet on master. |
Any progress @dvberkel ? I have played with it a bit a found a couple of issues:
|
I have opened an issue on tryocaml OCamlPro/tryocaml#167 |
I made some progress, but got side tracked integrating klipse in my blog. I wrote a blog post with clojure in mind to see what is to be expected. I will take a look into tryocaml and their environment |
@dvberkel Thanks for your initiative. Now Klipse supports Ocaml and ReasonML. See http://blog.klipse.tech/ocaml/2017/10/05/blog-ocaml.html |
Congratulations! Sorry that I couldn't find the time to bring this to fruitation |
This is very much work in progress. Feedback is much appreciated.