Very low number of Haxe [Target] books || tutorials

A new topic might be good to keep everyone in the spirit of spit balling tutorial ideas vs discussing if its a problem. Even if anyone disagrees about the state of Haxe tutorials, there is no one that doesnā€™t have an idea for something else theyā€™d love to use Haxe for.

I think in the end we just need to come up with a list of topics for cook book articles to make that part of the haxe page something to behold. The current ones have been fantastic and Iā€™d love to see even more of them!

1 Like

My two cents

The first obstacle to learning Haxe is the temptation to try and learn everything about the language. Honestly, I used Haxe for years without understanding all its features, and that was before new features were added. Thereā€™s a subset of Haxe thatā€™s needed for most everyday use. Thatā€™s something tutorials and lessons may be able to help with (helping you know what you need to know). When you walk into a Loweā€™s, Home Depot or other large hardware store, who tries to understand every tool in the store? That idea makes the learning curve seem more daunting.

The second biggest obstacle (other than not having more big names behind the language) is the sheer scope of what may be accomplished with Haxe. Think of it, you make a ā€œ2D platformer game engine JSā€ and you know have a very well defined set of tutorials and use cases to meet. Each new developer is on the same platform, running in a similar environment, trying to accomplish similar goals, so the language + framework result in a very natural focus of the community.

Languages themselves are obviously broader than frameworks, but generally speaking, you take a language such as PHP, and you can assume everyone is attempting to use MySQL, implement mem-caching and other problems you naturally work to solve in a certain environment.

C and C++ are much broader, but still (normally) do not run in a web environment, so thereā€™s still some limits to the scope. However, despite the huge success of these languages, I do not find there are many great resources for learning them. C++ and OpenGL, sometimes it feels like you are just assumed to understand already.

For this reason, Haxe is sometimes best learned if certain assumptions are made about who you are, and what you are trying to accomplish. We should have better learning resources at the OpenFL level, for example

3 Likes

Makes me wonder if the best thing wouldnā€™t be a ā€˜get started guideā€™ for some of the less utilized use cases of haxe. The web use cases are probably the first thing I think of as being a major reason to try haxe in the first place (having server and client code shared), but writing server code isnā€™t something we have as much to offer in terms of tutorials as we do game development.

A boat load of documentation would be pointless at this point, but we could certainly use a couple examples of getting started with a web server or command-line tools.

3 Likes

Web Server/Client is definitely one of the items I was considering. Iā€™m thinking of creating a tutorial for making a simple TODO app with tink_web that is backed by some sort of database. I think that would be a decent overview of building a website with haxe (but it might also be too much work for me to handle).

6 Likes

I agree, I think the Target Details is way too short. Itā€™s mostly for externs (which is great) but is missing more concrete use case. For example, in php/js a ā€œsimpleā€ CMS made with Haxe.
At the moment, we juste have a: hey you can code everything with Haxe, it exports to the correct platform! But since you might not be very familiar with this platform, you will start to learn more from it reading its original language. And Haxe will only be a barrier somehow.

If anyone wants to make tutorials / series, I invite you to write it on code.haxe.org. It is meant to be community driven and is free to access. Contribution is easy, just edit markdown files on Github. It also contains lot of beginner topics. As for target specific documentation, we need help on that too. The problem with documentation is that you never have enough :slight_smile:

1 Like

Btw books are waste of environment and are hard to update.

4 Likes

Things are moving so fast today (especially in js), that books are becoming obsolete very fast.

This is the strength of a community.

1 Like

I am working on several aspects for Haxe documentation for while now, I can confirm it can be the strength of the community, but since Haxe community is relative small its hard. All docs and tools are open source and easy to edit but seems not attractive enough, otherwise this post wouldnā€™t be created :slight_smile:

But like I said, everyone is welcome to contribute topics/articles/api docs/target details/snippets etc etc! Id love to help getting it online!

3 Likes

If we come up with a topic list Iā€™d love to help.

I recently started learning Go and I found their ā€œTourā€ to be excellent, Haxe should try and do something similar. I literally got most of the language figured out in a matter of hours.

The good thing about the tour was how easy it was it pick up the basics of the language and then nuances, all while you have live samples running where you can play and make adjustments.

Check it out here: A Tour of Go - Step through the ā€œWelcomeā€, then directly into the first lesson.

1 Like

I remember watching a talk where @back2dos was using haxe to compile PHP projects ( and his clients didnā€™t care, because the output was PHP and he made less errors, etc ). Would be interested in a small sample repo showing a minimum setup for this - would be a nice starting point for new projects :slight_smile:

Also this Haxe and JavaScript gitbook is definitely worth highlighting for beginners who are looking to get their hands dirty with haxe + html5. The git repo is super-structured.

1 Like

There was not much to it. I used FlashDevelop to create a new PHP project (but thereā€™s really not much in there except -cp src -php bin) with haxe.web.Dispatch for routing, haxe.Template for templating and SPOD for persistence. I did add tink_lang to the mix because Iā€™m a terseness fetishist, but that has largely superficial effects. Soon I did replace haxe.Template by tink_template so I would have type safety throughout all the code (and also a richer template language). All in all, it was pretty unspectacular :wink:

Thereā€™s actually a lot to that - itā€™s simple, not easy :slight_smile: For me itā€™s a great point from your talk and would illustrate easily how to switch from a typeless php to a typed haxe style. How about a github.com/back2dos/haxe-php-starter-template ? :stuck_out_tongue:

itā€™s giving 404 :slight_smile:

@back2dos please fix :smiley:

I have made some websites with haxe.Template, web.Dispatch and Spod (now called record-macros). I can made a simple blog system for php and neko when I have time this week.

1 Like

I am the one who create the php haxe documentation mentioned in the question asked by @socialflasher

I wrote it during the time I was learning about PHP and Haxe. It should cover most issues you will have when starting with PHP target.

And it also has examples about :

So perhaps we should update the git repo ā€¦

3 Likes