Skip to content
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

[Fix #495] Add some ClojureScript usage documentation. #911

Merged
merged 2 commits into from
Dec 19, 2014

Conversation

cichli
Copy link
Member

@cichli cichli commented Dec 7, 2014

This doesn't go into too much detail of how to set up a CLJS environment, since this is covered well by the documentation for Austin/Weasel themselves. I think one other useful addition would be minimal known-to-work versions of CLJS/Piggieback/Austin/Weasel, but this is complicated slightly by the fact that different versions of Austin and Weasel have different minimum CLJS versions (CLJS releases do not use SemVer and move pretty fast). Thoughts?

@bbatsov
Copy link
Member

bbatsov commented Dec 7, 2014

Seems like a good start, but I do think that some run instructions (at least for weasel) might be useful. Some users will likely be intimidated by the complete documentation of austin/weasel and would simply like to know how to get start a cljs repl with cider. I do wonder if it doesn't make sense to automate the boilerplate commands by wrapping them in interactive Emacs commands.

@bbatsov
Copy link
Member

bbatsov commented Dec 7, 2014

Seems that @symfrog has created something similar already https://github.com/symfrog/clojure-quick-repls

@cichli cichli force-pushed the clojurescript-documentation branch from f5e62d9 to ca21a44 Compare December 7, 2014 17:30
@cichli
Copy link
Member Author

cichli commented Dec 7, 2014

Agreed, especially with respect to the Austin documentation. I've added basic examples for starting both Austin and Weasel REPLs. Btw, seems like the Caveats section isn't the best place for this stuff - maybe a new section for ClojureScript between the Middleware and Configuration sections would be useful?

@cichli
Copy link
Member Author

cichli commented Dec 7, 2014

One difficulty with providing a command for starting a cljs repl is that there are several different REPLs (each requiring a dependency in the user's project) and several different evaluation environments (browser via HTTP, browser via websockets, Rhino, node.js, etc. etc.) and I don't know if it's useful to prescribe any particular one.

A lot of projects already define a browser-repl fn or somesuch to make launching their cljs repl from the clj repl easy, maybe we could provide a config option that takes the relevant user-defined function to call to launch the cljs repl.

@cichli cichli force-pushed the clojurescript-documentation branch from ca21a44 to a0c1108 Compare December 7, 2014 17:57
@bbatsov
Copy link
Member

bbatsov commented Dec 7, 2014

maybe a new section for ClojureScript between the Middleware and Configuration sections would be useful?

Agreed. Guess you can leave in the caveats just the portion about the unsupported functionality.

A lot of projects already define a browser-repl fn or somesuch to make launching their cljs repl from the clj repl easy, maybe we could provide a config option that takes the relevant user-defined function to call to launch the cljs repl.

Sounds reasonable. Given my lack of cljs xp I'll defer to your judgement regarding this.

@cichli cichli force-pushed the clojurescript-documentation branch 3 times, most recently from 9ebe13d to 150db32 Compare December 8, 2014 23:17
@cichli
Copy link
Member Author

cichli commented Dec 8, 2014

Okay, updated now. Moved all but the actual caveats to a new section and fixed up some indentation and formatting.

@cichli
Copy link
Member Author

cichli commented Dec 8, 2014

Btw do you auto-generate the table of contents? Happy to submit a PR to fix it up since it's a bit out of date but I'm not sure if it's maintained manually or not.

@bbatsov
Copy link
Member

bbatsov commented Dec 9, 2014

Initially I generated it with some node.js tool which I don't even
remember. After that I've been maintaining it manually.

On Tuesday, December 9, 2014, Michael Griffiths notifications@github.com
wrote:

Btw do you auto-generate the table of contents? Happy to submit a PR to
fix it up since it's a bit out of date but I'm not sure if it's maintained
manually or not.


Reply to this email directly or view it on GitHub
#911 (comment).

Best Regards,
Bozhidar Batsov

http://www.batsov.com

@symfrog
Copy link

symfrog commented Dec 9, 2014

@cichli Just a note that clojure-quick-repls does provide a customizable variable that can be defined by the user to customize the cljs repl that is launched.

Another major benefit of clojure-quick-repls is that it will automatically route forms over the correct repl connection depending on if you are in a clj or cljs buffer.

@@ -44,6 +44,7 @@ CIDER packs plenty of features. Here are some of them (in no particular order):
- [Installation](#installation)
- [Prerequisites](#prerequisites)
- [Installation via package.el](#installation-via-packageel)
- [ClojureScript](#clojurescript)
Copy link
Member

Choose a reason for hiding this comment

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

Btw, it seems to me this would fit best under Basic Usage.

@bbatsov
Copy link
Member

bbatsov commented Dec 18, 2014

@cichli Should I merge this as is or are you going to do the TOC changes you mentioned first?

@cichli
Copy link
Member Author

cichli commented Dec 19, 2014

Sorry for falling behind on this! I've moved it to Basic Usage and added a note about clojure-quick-repls (probably discussion for another issue but is it worth merging any of those features into CIDER proper?). I've also cleaned up the TOC.

bbatsov added a commit that referenced this pull request Dec 19, 2014
[Fix #495] Add some ClojureScript usage documentation.
@bbatsov bbatsov merged commit c197cd6 into clojure-emacs:master Dec 19, 2014
@bbatsov
Copy link
Member

bbatsov commented Dec 19, 2014

👍

(probably discussion for another issue but is it worth merging any of those features into CIDER proper?).

Yes, we should probably have something similar in CIDER itself.

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.

None yet

3 participants