Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

CheerpJ is the one I'm waiting for. That thing is wicked cool for Java.


While you wait for CheerpJ, please check out TeaVM:

https://teavm.org/

It has a permissive Apache license and numerous success stories:

https://frequal.com/TeaVM/TeaVmBasedSites.html

There is also a full SPA toolkit called Flavour Plus for making pure Java, web-native, full-stack web apps:

https://frequal.com/FlavourPlus/


Thanks, I've checked it in the past and recognize all the effort you've placed into the platform. There are reasons why it is mostly ignored:

+ website itself is difficult to find the hello world example

+ after a long time digging one finds the hello world, but is hosted somewhere else with (again) very scarce documentation on how to get it started.

+ the number of examples on the site is 2, and only one for Java language.

Please invest more on newbie first steps. It isn't that we (end-users) are lazy, it is just that our time is precious too and this kind of information being available makes a huge difference to gain confidence into quickly grasping the basics and grow into more complex cases. This isn't possible when losing so much time around the site for info and just 1 example as showcase. (I know more examples are on github, but again had to dig to find them). Even that second link you mention has interesting examples but again, not even listed on the main page.

If you compare to similar projects like GraalVM, you can notice they include snippet examples after snippet examples for end-users to dive quick and deep on what can be done: https://www.graalvm.org/latest/reference-manual/wasm/

My apologies for the long answer. It just pains me to see a good project and a motivated person like you answering here but still with the handicap of a site that pushes end-users away.


> + website itself is difficult to find the hello world example

I opened the website, saw a docs link, that had a "Getting started" section, and started wondering what you were talking about. Then realised all that gives is Gradle build instructions, a maven build command.

It'll tell me how to interact with javascript, use coroutines, all sorts of stuff, without actually giving me a very basic "Hello World" sort of example. I don't think I've ever come across a language / runtime that hasn't at least had a very simple example or two within their own documentation.

https://github.com/konsoletyper/teavm/tree/master/samples/he... seems to be where they have their hello world, but ... what am I even looking at? You're right, this is shockingly bad by way of a newbie experience.


> You're right, this is shockingly bad by way of a newbie experience.

Sorry, but what exactly were you expecting? I would improve documentation, but to me it looks ok. What sort of example you need? What's wrong with the Hello World link you posted, i.e. https://github.com/konsoletyper/teavm/tree/master/samples/he... ?


Almost every language has a simple walk through that goes step by step and explains what parts are, or gets you to the point of having your first working application.

Here you go "here's how to set up your build platform".. and good luck?

The content under that github repo doesn't explain anything. It's just a dump of code. Why are the various parts there, how does this interact with TeaVM, how does this interact with the web page and why?

The documents are written assuming knowledge, and the code does nothing to actually explain what is going on, how things should be laid out or anything. There's no readme, and no comments other than the license blurb.

How does someone with no familiarity with TeaVM at all, know how to even get started?

I appreciate writing documentation sucks, but if you want your project to take off, it's not enough for it to be good on a technical level. You need to be hand holding through the entire initial process. One of the things that is consistent right throughout technology is that the best solution isn't the one that gets chosen. It's the one that has the lowest barrier of entry, and the best user experience.

One of the things that catapulted Ruby from being some obscure language to immense popularity was the first Ruby on Rails tutorials that had you making a functional blog site, taking you from first line of code to functional site pretty quickly. Ruby wasn't that special or unique as a language, but suddenly this framework came along on it that was transformative (compared to the general state of the market) that made it easy to build a website and then start modifying it.

By way of contrast for your documentation, searching for rust webassembly takes me to https://www.rust-lang.org/what/wasm which has a link to an introductory documentation https://rustwasm.github.io/docs/book/introduction.html Then in the "Hello World" section, https://rustwasm.github.io/docs/book/game-of-life/hello-worl..., it explains what each file is, why, what's happening in them, and ultimately leads to you having a working example website.

To take another example, I just googled python and webassembly, which to me to pyodide's website. The first section of their site after the introduction to what pyodide is, https://pyodide.org/en/stable/usage/quickstart.html walks you through how pyodide works in the browser, how to get your code in and functional and gets to to a place where you've created a functional page.

Ruby's stuff around webassembly is pretty fresh and documentation doesn't seem to be linked from their website, but from a quick online search https://ruby.github.io/ruby.wasm/ appears to be there. Same story as with pyodide, albeit the documentation for ruby wasm is really bare right now, but it still gives you a quick example, explains how to put your code in to the site, or as WASI, and gets you up and running.

If you want TeaVM to take off, you have to make it easy for people to get started. Absurdly so. Walk them step by step to having a functional website leveraging it. Explain what's going on at each stage, and why various lines of code are needed. What they're doing. Build up their understanding that you already have.


A good introductory article is this one from Java Magazine:

https://blogs.oracle.com/javamagazine/post/java-in-the-brows...

A good collection of specific, detailed how-to's for various use cases is in Tea Sampler here:

https://frequal.com/tea-sampler/

A more general collection of education and advocacy articles are here:

https://frequal.com/TeaVM/

I do agree that more needs to be written about this mature, permissively-licensed tool that makes Java work in modern browsers. Hopefully these links are a start.


Do I understand it correctly that you are the one behind TeaVM? If so, would be interested to help out with the documentation if you can reply to this message with your email


Hello. No, I'm the one behind TeaVM. You can write me on `info at teavm.org` or send me a message via Gitter (https://app.gitter.im/#/room/#teavm_Lobby:gitter.im) or post a message to Google Groups or on Github discussions (https://github.com/konsoletyper/teavm/discussions)


If you can include those links on the main site it would certainly help many others with the same difficulties.


Cheerpj or Teavm would be amazing if they would be able to convert pdfbox to wasm as a library that runs on wasi and the web.



It's not open source


Yes, unfortunately, the more advanced products are much more restricted.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: