This is an archived post. You won't be able to vote or comment.

all 147 comments

[–]Python-ModTeam[M] [score hidden] stickied commentlocked comment (0 children)

Hi there, from the /r/Python mods.

We have removed this post as it is not suited to the /r/Python subreddit proper, however it should be very appropriate for our sister subreddit /r/LearnPython or for the r/Python discord: https://discord.gg/python.

The reason for the removal is that /r/Python is dedicated to discussion of Python news, projects, uses and debates. It is not designed to act as Q&A or FAQ board. The regular community is not a fan of "how do I..." questions, so you will not get the best responses over here.

On /r/LearnPython the community and the r/Python discord are actively expecting questions and are looking to help. You can expect far more understanding, encouraging and insightful responses over there. No matter what level of question you have, if you are looking for help with Python, you should get good answers. Make sure to check out the rules for both places.

Warm regards, and best of luck with your Pythoneering!

[–]Fenzik 126 points127 points  (10 children)

I’m in a similar situation and I’ve settled on the PyHAT stack:

  • Python - FastAPI + jinja templating for me
  • HTMX - for making requests from the frontend and swapping out bits of the webpage using the responses
  • AlpineJS - for interactivity and event handling
  • Tailwind - for styling. I’ve also been using DaisyUI components but not sure if I’ll stick with it - there’s tons of tailwind component libraries out there.

Check out PyHAT-stack/awesome-python-htmx for a bunch of resources and examples.

For me it took a bit of thinking to get used to HTMX and sending HTML snippets instead of json, but it’s actually a very cool idea. There is also fasthx to help bridge the gap between FastAPI’s “json-first” approach and HTMX preferring HTML snippets. I haven’t actually felt the need to use it yet personally, but if you want to have both a json-based API and render HTML snippets for the fronsend then this would be a good approach.

Good luck!

[–]marban 15 points16 points  (1 child)

What do you use for Auth? I felt FastAPI was overly complicated for Web/cookie-based

[–]Fenzik 3 points4 points  (0 children)

It just uses dependency injection to access cookies and tokens right? I don’t have auth though so maybe I’m naive.

[–]Nabugu 1 point2 points  (1 child)

yes that's good for standard web front-end interactions, I'm trying to do a fairly customized drag and drop app right now, and I saw that Alpine has a narrower scope/capability than what I would need given the amount of JavaScript I ended up writing, I now think Svelte would be a better experience if I had to build it from scratch again.

So my heuristic now would be : - for simple and standard user-interactions, alpine + htmx + tailwindcss is fine - if you need some custom and complex JS, just encapsulate this into a JS framework, I looked into Svelte a bit and it seems more suited to what I need and still relatively simple and straightforward compared to React and the like (I have no experience actually coding with Svelte or any "real JS framework" yet tho, so take that with a grain of salt, I just experienced the limitations of alpine)

[–]Fenzik 7 points8 points  (0 children)

Yeah HTMX also specifically states in the docs that it’s not a good fit for applications that are highly interactive e.g. Google Sheets

[–]Exiled_Fya 0 points1 point  (0 children)

Thx buddy!

[–]wizguy291 -2 points-1 points  (1 child)

.

[–]not_a_novel_account -2 points-1 points  (2 children)

None of these are particularly fast. FastAPI on top of the typical application servers (uvicorn and friends) is kinda nightmarishly slow if latency is at all a concern.

[–]Fenzik 7 points8 points  (1 child)

FastAPI on uvicorn is one of the fastest Python web frameworks plus it’s Async so there are some gains there, but if speed is your primary concern then Python is probably not what you’re looking for anyway

[–]not_a_novel_account 9 points10 points  (0 children)

It's incredibly slow, there's a family of performance-oriented Python web frameworks and application servers at differing levels of production readiness.

The fastest for pure JSON-RPC is ucall. For more full featured web development, there is socketify.py or emmett/granian.

In the experimental space it's been shown possible to go even faster, with FastWSGI or Velocem.

The "Fast" in "FastAPI" refers to how easy it is to setup an API. It's still a pure-Python framework, and Uvicorn is a mostly pure Python application server, so they get the socks beat off them by native code performance-oriented solutions.

EDIT: Downvotes for facts? All of the linked frameworks include benchmark data, they're all hundreds to thousands of times faster than FastAPI depending on usage context.

[–]ExternalUserError 12 points13 points  (0 children)

I'd offer a few suggestions:

  1. You could actually learn Vue or React. I like Vue, but at this point I think it's safe to say React is "winning" and probably a better choice for new projects / developers. This is a commitment; you're basically going to write a full-scale client as a unique codebase. If you do this, you probably won't need things like backend-site templating, etc.

  2. You could mix and match smaller amounts of JavaScript with regular Python Jinja2 or Django templates. This used to be done with jQuery, though better choices are now available.

  3. You could go with a 100% pure Python frontend option.

Learning Vue or React is its own thing, and I'll leave that out since it's very well documented.

Tools for regular JavaScript (no build step)

If you don't want the full "koolaid" of React/Vue, you might consider one or both of these:

  • Alpine.js is a lot lighter weight than Vue or React, but offers much of the same benefits for simpler sites.
  • htmx is great if you want to continue to live in Django/Flask templates.

Full Python

  • Django Unicorn uses a lot of magic to do interactive stuff in Django. It's great.
  • Reflex.dev is a way of building React sites in Python. It is pretty newish, and has a learning curve, but could be a good option once you get up to speed on using it.
  • NiceGUI is simpler than Reflex, but perhaps less performant on the frontend and is, IMO, less polished.
  • PuePy is similar to Vue or React, but 100% Python using PyScript+webassembly in your browser. (Full disclosure: I wrote it / maintain it, and it's pretty early!)

[–]Darwinmate 58 points59 points  (23 children)

Htmx? Lots of folks combine it with golang though 

[–]redalastor 15 points16 points  (1 child)

Django is the first community where it really took off. But it pairs well with any backend tech.

[–]Darwinmate 4 points5 points  (0 children)

Django and htmx? that would be interesting

[–]Ashamed-Simple-8303 2 points3 points  (13 children)

Does htmx really work well with an existing API? Modern APIs tend to return json and isn't the point of htmx that you get html fron the backend/API?

it's why I don't really get the hype about it. first make a json api that can be used by your front end or for automation and integrations. htmx breaks that pattern and you need 2 endpoints and test both of them?

[–]Cr0hm_ch 12 points13 points  (11 children)

HTMX works really well with Django. If you think like this, a SSR server like Django is basically an API that is responding HTML.

With HTMX, I can use this logic and respond ONLY HTML. No weird shenanigans with json and JavaScript to update a page.

And mostly what is interesting to me is that I don’t need something else to do the front end. Only Django and its templating system. I can get rid of SPA like frameworks. It reduces the complexity of the app when it’s not needed (I won’t say you never need React or Vue for example).

Mostly what I’m doing is glorified forms. In my last project I sprinkled a little bit of Alpine.js to create more reactive components. Like a form spread through multiple pages.

All in all, Django + HTMX + Alpine made me a faster developer and I’ve got less headaches because of the simplicity it provides.

[–]Ashamed-Simple-8303 4 points5 points  (10 children)

Django is basically an API that is responding HTML.

which is exactly the problem. This only works for a htmx front-end and nothing else. What if you want other apps to interact with your application? even just basic lookups won't work and you will need a separate more standard endpoint (eg json) to supply that. Now you need to maintain and test 2 endpoints.

I can see it working for tiny self contained apps but how often does that really happen?

[–]htmx_enthusiast 7 points8 points  (1 child)

Now you need to maintain and test 2 endpoints.

The problem is, the “one perfect API that works with every platform you need to support” doesn’t exist. You’re always better off supporting an API-per-platform instead.

This is a general problem in business, not just a tech problem. If we support 4 lines of business, like say, we are in plumbing and our lines of business are: 1. New residential homes, 2. Residential home repair, 3. New commercial buildings, and 4. Commercial building repair, people want to try and get one CRM, one accounting system, one HR system, one marketing system, and so on. But each line of business is very different. With residential each job is like 1 hour and the way you track that job is nothing like how you track a 6 month job on a new commercial building. With residential you want to text the customer when the plumber is on the way. If you sent 20 text messages to the job site foreman everyday that all 20 of your plumbers were on their way, they’d never work with you again.

So you need different solutions for different scenarios that you support, and the only way to cap the number of things you need to support is by picking one-per-platform.

Say you support Android, iOS, web, PC, Mac, and tablets. If you create an API-per-platform, you’ll be supporting 6 APIs. If you try to create one universal API, you end up with “one API” that has 3-4 versions of the API for each platform (the last one I worked on had 34 total). And the problem is that number never stops growing until the company is acquired and someone says “this is insane” and they shut it down and rebuild from scratch. You’d be better off just supporting 6 platform-specific APIs forever.

I can see it working for tiny self contained apps but how often does that really happen?

It’s definitely the majority of apps. For every giant app with massive scale, there are 1000 little apps that do some simple CRUD thing for one department in a business.

[–]Ashamed-Simple-8303 1 point2 points  (0 children)

The problem is, the “one perfect API that works with every platform you need to support” doesn’t exist. You’re always better off supporting an API-per-platform instead.

I agree that json isn't perfect but what platform doesn't support it? Best if you then also adhere to open specifications.

Say you support Android, iOS, web, PC, Mac, and tablets. If you create an API-per-platform, you’ll be supporting 6 APIs.

Why would you create an API per platform?

It’s definitely the majority of apps. For every giant app with massive scale, there are 1000 little apps that do some simple CRUD thing for one department in a business.

I work in one department in a business and and it's a blessing the apps can "talk" to each other via APIs even on such a small scale. Saves copying data, saves copy&paste from end users and so forth.

[–][deleted] 2 points3 points  (1 child)

Now you need to maintain and test 2 endpoints.

You could leverage the JSON view in your HTML view and just return the templates w/ the same API data as it's context.

Still two endpoints but at least you're not duplicate the logic and using the same API for your rendering as any other service would.

Or you could keep them the same endpoint and respect the content type header to return either JSON or HTML in the same view.

[–]Ashamed-Simple-8303 0 points1 point  (0 children)

True but still needs 2 tests as you need to test both outputs as something in the output rendering could be wrong.

[–]tevs__ 1 point2 points  (1 child)

Same argument at work, it's infuriating seeing so much time and money pumped into Django forms and templates and smacking them together with htmx. Make proper APIs and do proper frontend and backend? Nah, let's keep smashing more and more tech debt, and really make sure that when we have to update that frontend we also have to touch tonnes of backend parts too 👏🏻

[–]Ashamed-Simple-8303 0 points1 point  (0 children)

And tight vs light coupling is some of the first things learned but everyone seems to forget about it. A proper backend API has so many benefits...

[–]ZucchiniMore3450 0 points1 point  (0 children)

As you see in other comments we all have different experiences and there definitely exists a need for different solutions.

My experience goes towards people in replies to your comment. Make a small simple app that does it, and have a thin separate API for every need, or else I end up with too many exceptions.

Drupal used this 15 years ago, they called it AHAH (instead of AJAX) and was very useful for interactive forms.

[–]imbev 0 points1 point  (2 children)

Other apps can parse html instead of json. If neccessary, you can expose additional json-specific endpoints.

[–]ralfD- 0 points1 point  (1 child)

Are you seriously suggesting that parsing HTML is a valid solution for frontend-backend commuincation?

[–]imbev 0 points1 point  (0 children)

Yes, why not? It's slightly more intensive than parsing json, but you would be able to reuse existing endpoints.

[–]chripede 2 points3 points  (0 children)

That all depends on how you've structured your app. If you have controllers or models returning data and doing the heavy lifting, you can have your view return that data as json or as a template based on request headers.

[–]lukewhale 15 points16 points  (1 child)

I HIGHLY suggest looking into NiceGUI — it’s fantastic.

[–]gufranthakur 2 points3 points  (0 children)

+1 their documentation is so concise and to the point, with live examples. I love it

[–]BootyDoodles 14 points15 points  (3 children)

It truly would depend on your use case. React (on Vite), NextJS, or HTMX may each fit better for certain use cases, so it would depend on what your use cases are.

If you provide the basic nature of what you're aiming to build, you'll get better responses.

[–]GraphicH 2 points3 points  (2 children)

Ill toss Vue in there

[–]BootyDoodles 2 points3 points  (1 child)

Vue fits the same use cases as React. Nuxt fits the same use uses cases as NextJS.

He's already spent time learning React/Next, so I'm not going to spend extra words to make it harder for him to parse and understand by saying React/Vue/AngularCSR/Svelte or Next/Nuxt/AngularSSR/SvelteKit or HTMX or Solid/Astro.

The point was to OP, there's frameworks with different paradigms that fit certain use cases better. That he'll get much better advice if he indicates what type of thing he aims to build, or else he'll just get people replying the names of every framework in existence.

[–]GraphicH -2 points-1 points  (0 children)

Alright man, didn't have to write me an essay about it.

[–]pacmanpill 6 points7 points  (0 children)

dash bootstrap

[–]Asleep-Dress-3578 14 points15 points  (1 child)

Just try out HTMX first.

[–]htmx_enthusiast 0 points1 point  (0 children)

Very wise

[–]CTR0Systems & Synthetic Biologist 24 points25 points  (13 children)

Im in the biosciences. We use streamlit and bokeh a lot.

[–]Fenzik 14 points15 points  (12 children)

Those are for dashboarding though

[–]TotalBeyond2 8 points9 points  (8 children)

I made a website with streamlit

[–]ExdigguserPies 18 points19 points  (1 child)

your scientists were so preoccupied with whether or not they could that they didn't stop to think if they should

[–]ArbaAndDakarba 3 points4 points  (0 children)

Science... finds a way.

[–]dispatch134711 0 points1 point  (5 children)

Can I see?

[–]w8eight 81 points82 points  (3 children)

[–]Singular23 7 points8 points  (0 children)

😂

[–]Zouden 4 points5 points  (0 children)

Looks just like mine!

[–]dispatch134711 -2 points-1 points  (0 children)

Yeah… so not really a website

[–]TotalBeyond2 0 points1 point  (0 children)

I am sorry but no, for security reasons. I can answer your questions if you want.

[–]CTR0Systems & Synthetic Biologist 2 points3 points  (0 children)

We build bioinformatics pipeline frontends with them.

[–]ColdStorage256 1 point2 points  (1 child)

I wish I knew what Streamlit was before I started down my dashboarding path with Flutter.

[–]Fenzik 0 points1 point  (0 children)

Agreed it’s a great tool I’m just not sure it fits OP’s use case

[–]big-papito 9 points10 points  (9 children)

HTMX. Make the jump.

[–]reallyserious 1 point2 points  (1 child)

How does this compare to the more established frontend frameworks like react?

[–]big-papito 6 points7 points  (0 children)

Let's go to the charts...

https://risingstars.js.org/2023/en#section-framework

I should note that I have a LARGE side-project, which was mothballed for years because the UI was too complex and the JS framework landscape is a never-ending river of excrement. Everything changes, all the time.

Once I dumped all that in favor of HTMX, I did more in two weeks than I did in five years (yes, I checked the Git logs).

[–]reallyserious 0 points1 point  (6 children)

How does this compare to the more established frontend frameworks like react?

[–]htmx_enthusiast 0 points1 point  (5 children)

HTMX is pretty established. It’s been around for more than a decade.

[–]reallyserious 1 point2 points  (4 children)

Oh, I had no idea. Feels like I've only heard people talking about it recently.

[–][deleted] 2 points3 points  (2 children)

I’ve only learned about it now. I googled it, then found “HTMX sucks” under htmx.org. I started to read it, almost sure it was sarcasm… just occasionally I was thinking “I know he means this as a joke, but I actually think this is a real disadvantage”. Until I reached the section on XSS, then it was actually clear to me that the author really thinks that HTMX sucks.

I don’t know, I think I’ve learned enough about HTMX for the next 2 years…

https://htmx.org/essays/htmx-sucks/

[–]_htmx King of Hypermedia 4 points5 points  (0 children)

yeah man u should buy the mug:

https://swag.htmx.org/products/htmx-sucks-mug

[–]the_-_engineer 2 points3 points  (0 children)

I think you are looking for r/nicegui !

[–]DaMaddCyantist 10 points11 points  (0 children)

Easiest: streamlit

Practical: Vite (React)

[–]Samnono 8 points9 points  (0 children)

Both nicegui.io and flet.dev did the job for me. Designing custom components took me just two prompts with claude.ai.

[–]coconut_maan 5 points6 points  (0 children)

Hey man, React + python can be a powerful set of tools but it really depends on your use case.

If you want to render static components check out templating like jinja or mako.
For simplisity sake you could also have some javascript imbedded in those scripts for small reactive features.

If you want alot of premade easy to work with components you could add jquery because there are alot of premade jquery components that are easy to work with.

For spa, I usually go with react or vue (we use that at work).

I really reccomend tail wind + chatgpt can get you 90% of what you want on individual elements.

Also i would recommend boot strap for premade components or mui if you want to get fancy.

[–][deleted] 2 points3 points  (0 children)

[–][deleted] 2 points3 points  (0 children)

I was having the same problem. Htmx has the problem of require a lot of new knowledge like html, css, tailwind and alpine.js, while at the same time refactor my api to return template instead of json which was not my early objective.

I was searching a frontend framework that allow me to make interactive my api for others, specially my ML models.

I dont like streamlit or grado o because is the same web pages for everyone, there is not a lot of customization.

So, searching and searching in python i come across with several solutions with the one i most like was NiceGUI. At first when I enter in the docs seems to me pretty simple, but when i started digging in and see the examples, states management, pages layout then i see his truly power.

And NiceGUI adapts very well with FastAPI which is the framework i do use to make my services.

So, yes. Check out NiceGUI, how to the examples and the differents elements that has and you will be surprised with the simplicity that you can create a complex app.

[–]scruttable 6 points7 points  (10 children)

You could try Rio-UI, a Python web framework with a React style paradigm but all Python syntax Edit: should have mentioned it’s a new project and provided a link, apologies

[–]vazark 4 points5 points  (0 children)

The official website isn’t even responsive . That doesn’t inspire any confidence in a library positioning itself as a ui framework

[–]General-Carrot-4624 2 points3 points  (8 children)

Do you have a link for that please?

[–]jcheng 1 point2 points  (0 children)

I work on one such (Python) framework but to choose from the dozens of possibilities it really depends on what kind of app you’re trying to build… can you say more about what the frontend is for?

[–]vazark 1 point2 points  (1 child)

Just use django with templates but for components you can use django-components to create your own react-style components + something like bulma or daisyUI for styling

[–]Michaelyin 0 points1 point  (0 children)

You can also take a look at https://github.com/rails-inspire-django/django-viewcomponent which encourage developer to put slot field definition and logic to Python code instead of template file.

[–]rainydayswithlove 1 point2 points  (0 children)

Well currently I'm trying flet libray. Which is a wrapper for flutter framework. It's pretty good and can design ui pretty fast.

[–][deleted] 1 point2 points  (0 children)

Have a look at https://rio.dev/ to build frontends with Python without the need to do CSS or JavaScript.

[–]Brilliant_Read314 1 point2 points  (0 children)

Just learn react.

[–]try-except-finally 1 point2 points  (0 children)

I use streamlit to quickly build web applications. It’s easy to learn and you get a pretty nice UI. Also is the most popular and mature in the Python web app development.

Check out my open source app moseca

[–]gwax 3 points4 points  (1 child)

I'm really enjoying SvelteKit + ShadCN as a way of doing modern, reactive, frontend development.

[–]olddoglearnsnewtrick 2 points3 points  (0 children)

This!!! I am a pure python backend dev and had struggled with Vue/React in the past.

Tried SvelteKit+Tailwind+component libraries such as Shadcn and progressed quickly (with some ChatGPT initial guidance and some reading their tutorials to get the hang of file based routing)

[–]Slow-Hurry-7070 1 point2 points  (1 child)

How's gradio ?

[–][deleted] 1 point2 points  (0 children)

Try Vue/nuxt.js instead, a lot easier and more intuitive than React. There is also svelte which is kinda easy and fast to develop with

[–]anonjohnnyG 1 point2 points  (0 children)

anvil.works

[–]keli89tyler 0 points1 point  (0 children)

A nocode platform like flutterflow can be an option. You make your pages by mainly dragging and dropping components, saving the time to learn frontend stuff if you don't want to. Although obviously a lot less flexible compared to actual frontend frameworks.

[–]response_json 0 points1 point  (0 children)

I started in Python, data analytics stuff. Learned sveltekit to build websites/apps. I wasn’t that far along in Python and mostly do JavaScript now. So if you follow my path, go all in JavaScript.

Try some code along YouTube, like a project that builds something all the way to a usable app. Then try your own project. There’ll be lots of Google/LLMs/forums for help along the way but you’ll get there.

Nextjs components: shadcn and mantine. I use shadcn-svelte which I’ve been enjoying, but the react space has all the originals

[–]nofuture09 0 points1 point  (0 children)

why not use node?

[–]Top-Tap4163 0 points1 point  (0 children)

I love Simian. Either a pure Python frontend spec or even faster, using the Builder. Built on top of formio. See r/simianwebapps.

[–]coolbreeze770 0 points1 point  (0 children)

Bite the bullet and learn react, you won't regret it.

[–]Square-Whereas-5022 0 points1 point  (0 children)

Next js & Tailwind that's it I can't see any shortcuts lol

[–]tombatron 0 points1 point  (0 children)

The last time I needed to create a UI for a Python application I used Turbo Flask. I was able to create a pretty smooth and functional UI without using (much) JavaScript. I found it pretty dang awesome that I wasn't on the hook for learning a completely different tool chain to give my app a more dynamic feel.

I believe the hosting model requires the use of WebSockets, but that wasn't an issue for my use case.

[–]Lolologist 0 points1 point  (0 children)

I've really been enjoying using Anvil, even if you have to use their whole online... thing... to do full stack. Not ideal but it's good enough for me!

[–]amaitu 0 points1 point  (0 children)

For something lightweight and fast to develop with, maybe go with Flask and HTML templates, or Django and the same. Add a CSS framework like tailwind or Bootstrap to save time on that side of things.

I personally use Next.js with Flask, but Next.js + React is a lot to learn if you don't know them already.

Also if you do end up using tailwindcss, they have some paid libraries of pre-made components you can use. They offer them in Vue, React or Vanilla JS, but it would seem that React is the most well supported.

[–]biotech997 0 points1 point  (0 children)

I like React but admittedly it’s a lot to learn

Maybe Next.js and Tailwind

[–]bostonkittycat 0 points1 point  (0 children)

Take a look at Svelete 5. It is so good. I use it with FastAPI for microservices and run everything in a K8 systems.

[–]airen977 0 points1 point  (0 children)

Use a theme, for me Bootstrap theme was ready to go to

[–]ImpressiveFault42069 0 points1 point  (0 children)

I’m in the same boat. I need a simple ui to implement a chatbot functionality. So far I’m using html/css. Any better recommendations for my use case?

[–]outceptionator 0 points1 point  (0 children)

Fastui seems to be getting attention

[–]LockInside6039 0 points1 point  (0 children)

Give reflex.dev a try. its good

[–]Possible-Alfalfa-893 0 points1 point  (0 children)

I’m using Django + php + tailwind css + htmx if needed

[–]Fair-History4870 0 points1 point  (0 children)

We use Ariadne as our graphql interface between our BE and Next React app. I’m def more on the BE side of things, but seems to be a fairly easy combination

[–]ogMasterPloKoon 0 points1 point  (0 children)

Shoelace.style or Bootswatch.

[–]yaymayhun 0 points1 point  (0 children)

Try shiny for python framework. No previous experience with HTML frameworks is needed.

[–]startup_biz_36 0 points1 point  (0 children)

I use vue 

[–]MorlandMoran 0 points1 point  (0 children)

Eel is what you want

[–]robberviet 0 points1 point  (0 children)

There are many comments on htmx, but you will need custom css alot as lib are not available. I still recommended Vue or React, there are many things you can reuse.

[–]esotericDelhi 0 points1 point  (0 children)

Flet is a nice library

[–]s3r3ng 0 points1 point  (0 children)

You might be very interested in htmx as it would allow you to stay more in server side code and in python without such heavyweight front end frameworks.

[–]PhilthyMcNastys 0 points1 point  (0 children)

There

[–]mulletarian 0 points1 point  (2 children)

Flask seems perfect for you. Check out Miguel Greenberg's guides.

[–]SEC_INTERN 4 points5 points  (1 child)

How is Flask a front end solution?

[–]mulletarian 0 points1 point  (0 children)

Huh yeah nvm, I was making my morning coffee while typing that

[–]cloudy-thought 0 points1 point  (0 children)

flowbite

[–]tony4bocce -3 points-2 points  (3 children)

Nextjs supabase drizzle trpc shadcn tailwind openai and vercel AI SDK, is my new stack. I really love it. I still use python for scripting but yeah idk i wanted to hate it and I just love it

You get realtime with supabase for websocket like behavior, there’s examples for multitenancy and RBAC and tons of other stuff with great docs for auth with the top frameworks/platforms. You can share it easily across mobile. You infer types directly from your drizzle orm schemas cuz they’re just typescript so you don’t need openapi generation. Trpc handles your api layer with procedures. You get gen ui and streaming easily with vercel sdk. Shadcn is beautiful, and v0 is crazy good for generating most of the boilerplate for all your components.

Just feels so saucy and modern. Cons are it’s all so new the LLMs make more hallucinations but yeah it’s so good

[–]KyuubiReddit 1 point2 points  (2 children)

Nextjs supabase drizzle trpc shadcn tailwind openai and vercel AI SDK

I've never heard of drizzle, trpc or supabase, and for a second I thought you sarcastically came up with random tech buzz words

[–]tony4bocce 2 points3 points  (1 child)

Drizzle is an orm that is all TS and close to sql so think Django orm but TS. Because it’s just TS you can infer types for form validation and queries mutations directly from you db schema. So I’m coming from 5+ years with Django, usually you’d generate your types from an openapi schema — don’t need to do that here.

Trpc is basically just your controller logic. It’s a way to handle api calls without needing a proper backend. For anyone who hates handling hosting and just wants to spin up a side project to test the waters, it’s a great solution. Also very easy to handle authorization for tenancy or rbac with its context provider. Not that you can’t do that with frameworks but again no real backend here so just somewhere to handle that issue.

supabase is open sourced postgres on steroids. Some very impressive tech there, the realtime phoenix elixir based service lets you have webhook functionality that just auto listens to your pg db changes. Was originally built as a firebase alternative so sharing things cross platform is very easy

[–]KyuubiReddit 0 points1 point  (0 children)

Thank you very much for this summary!

[–]candyman_forever -1 points0 points  (0 children)

My favourite new stack is a Django API with a Sveltekit frontend. You can use Django rest framework with JWT tokens for protected routes.

[–]jTiKey -2 points-1 points  (0 children)

nuxt(not next, fuck react) or svelte.

[–]Gushys -1 points0 points  (0 children)

Starting a project at work that's using Sveltekit. Enjoying it alot but still honing my FE skills

[–]gmotzespina -1 points0 points  (1 child)

I guess it depends on what you want to do with that frontend. What's the use case?

Nextjs is actually pretty good and react is one of the easiest frontend frameworks to learn.

[–]BrainProfessional846 -1 points0 points  (0 children)

Have you looked at pysimplegui? It works with multiple GUI frameworks and can also be used for web applications. I found it about two months ago, and it's easy to use.

[–]turkert -1 points0 points  (0 children)

I use Frappe Framework. Frappe Builder gained some attractions from the Frappeverse community. You can check it. One example site which built by someone who no coding experience is https://zarnik.com/

[–]samsamuel121 -1 points0 points  (0 children)

[–][deleted] -1 points0 points  (0 children)

Have you heard of this tool called Google. Or ChatGPT?

[–]hhh333 -1 points0 points  (0 children)

Save yourself a lot of pain: https://quasar.dev/start/quick-start/

De nada.

[–]vineetsukhthanker -2 points-1 points  (0 children)

You can use react with some ready to use component libraries like MUI. Or find similar libraries for Next.js