by deepskyai on 11/7/23, 12:06 PM with 12 comments
- There are lots of web development frameworks in python: Pyscript, Anvil, Reflex, Atri, JustPy and many, many more
- The docs or mini courses for these jump straight into “how to do a web thing that we already know but in Python”
- No course out there teaches the basics of the web like fetching, async, dom manipulation with Python not even the PyScript stuff which has a mandate to teach people web.
- I had to learn JS before i could understand the courses that teach the basic concepts of the web
So HN, why is it this way?
by fermigier on 11/8/23, 9:16 AM
I believe a sensible approach, for some (including me), is:
1. Learn back-end web programming (HTTP request/response model, templating, sessions, security, the REST architectural model, ORM...) with your framework of choice (Django, Flask, Litestar, Sanic...). There are many tutorials and books around.
2. Learn HTMX (https://htmx.org/). A fine book is https://hypermedia.systems/ (it will also teach you the fundamental, framework-agnostic, principles of 1.)
by hiccuphippo on 11/8/23, 5:29 PM
by mtmail on 11/7/23, 12:29 PM
by wtbdtloopsody on 11/7/23, 7:24 PM
there's just no need and no advantage of Python in Web Dev except maybe fun and the love for "quick and dirty" ...
but if you keep adding and building, they will come ;]
by rbanffy on 11/7/23, 12:15 PM
I am not sure what you mean here. There’s not really much space for Python in the browser. When you mean using Python to scrape web pages, there are specific courses. The HTML web frameworks output usually has very little, if any, front-end code in tutorial in order to make the example simple, because the goal is to teach rather than provide real-world examples.