Fork me on GitHub

[meander/delta "0.0.76"]
is available. The pattern matching and substitution compilers emit much better code than previous versions with more optimizations. The performance improvements are dramatic on both fronts.

👍 4

We’ve got a tutorial in the works with an open pull request for folks looking to learn how to use Meander in practice. I must apologize for doing a poor job on explaining the utility and philosophy of the library in the README! My primary focus has solely been on building the library itself rather than “marketing” it. Pending a release of a good tutorial and improvements to README, I’m happy to respond to questions at the project homepage and in the #meander channel. 🙂

👍 32

A novel addition to the latest branch of the project (`delta`) is the ability to express recursive patterns. Have a look! Give it a try!


(Send me bug reports! 😅 )


Use 0.0.76 not 0.0.74 (just found a small bug). 😉


Published a beginner friendly blog post on deploying ClojureScript to Github Pages

🚀 24

Thank you for taking the time to write and publish this. It may seem simple but I couldn't find a similar article back in the day. I've been using Netlify ever since (found it easier to begin at the time) but using GitHub pages seems to be just as simple.

🙏 4

I recently did a video of using ClojureScript, figwheel-main, reagent and Bulma CSS framework for deployment on GitHub pages;list=PLy9I_IfUBzKJSgctCJaRYcnF6kZdiZ5ku&amp;index=23 Nice to see the different approaches.

👌 24
👍 4

@tkjoine Would 'static' here accommodate a self hosted ClojureScript site? No server, database, server side requirements, but fully 'active'


Good question. TMK it should, but maybe I am missing something.


Maybe this is another example of Serverless computing 😁


@tkjone I gave it a try and got an error.

$ clj -m cljs.main -d "demo-clojurescript-gh-pages/out"  -c demo.static-website -r
Exception in thread "main" Could not locate cljs/main__init.class, cljs/main.clj or cljs/main.cljc on classpath.
I poked around a bit and there were some comments about issues with java 9 but I am running java 8. Any ideas?


Hey @U0XTHMGMP, what does your current folder structure look like? and what does your static_website.cljs look like? I just switched over to Java 8 and it’s still working for me.


What is the -d option anyway? I do not see any documentation for it. When I take it off things seem to work fine.


Interesting. -d is a ClojureScript compiler option: allowing us to set the output dir of our compiled ClojureScript. You can check out more options at the above link, or via command line:

clj -m cljs.main -h
You can for sure remove that flag, but if you do you should not be able to see a console log in the browser console


Having said the above, I am able to reproduce the error your specified. It happens for me if I run the following command

clj -m cljs.main -d "demo-clojurescript-gh-pages/out"  -c demo.static-website -r
In a dir which does not have a deps.edn file


Interesting, if the directory demo-clojurescript-gh-pages is present there is no problem.


Yup. I wrote a footnote that hopefully explains this in greater detail because I figured it might not be clear


Let me know if you have any suggestions for how to make this clearer as I feel it is something that will come up more often than not. Suggestions and feedback are very welcome 🙂


It might be good to add a { :paths ["src"] ... in the deps.edn. I think that is the default. Also from the instructions is sounds like the clj command should be run from the src/demo directory.


Awesome. That makes sense and would explain what happened to you. I will update. Thank you!


I think the actual issue was that the deps.edn file had not yet been processed successfully. The unknown -d option having prevented a successful first run. I think what did the trick was running clj -m cljs.main -h which effectively retrieved clojurescript. I then created the "missing" directory and the next run succeeded.


Oh wow. That’s interesting. I cannot speak to your case, but I can say that I deleted all local versions of ClojureScript and noticed that even if I ran the clj -m cljs.main -d ... command from the correct place, it would not download ClojureScript. I then deleted each directory generated by clj (because I still had the previously generated dirs from successful runs) out, demo-clojurescript-gh-pages and .cpcache and identified that if a .cpcache directory is present, ClojureScript will never (?) be downloaded (even if it is nowhere on the local). This includes if you run clj -m cljs.main -h and also if :paths is specified in deps.edn. In your case though, I would have to know where the commands were run. Either way, I def’ learned about some interesting behaviour 🙂


Me too. Thanks.👍


I have also been looking at the --output-to option for the production build.


Yeah, that’s a good one too. I will post a more “best practices aligned” version of the demo in a few days to show how I might actually configure this if I was trying to maintain a static website and not just a demo


I recently did a video of using ClojureScript, figwheel-main, reagent and Bulma CSS framework for deployment on GitHub pages;list=PLy9I_IfUBzKJSgctCJaRYcnF6kZdiZ5ku&amp;index=23 Nice to see the different approaches.

👌 24
👍 4