FastUI & Pydantic - Build Interactive UIs with Declarative Python code

Поделиться
HTML-код
  • Опубликовано: 18 янв 2025

Комментарии • 95

  • @jefralston
    @jefralston Год назад +28

    More videos on this framework please. You do a fantastic job in all of your videos. I love the way you explain things line by line.

    • @bugbytes3923
      @bugbytes3923  Год назад +2

      Got it - will have a think about what to do next. Thanks!

    • @themarksmith
      @themarksmith Год назад

      @@bugbytes3923 Would love to see this working in Django with templates/postgres based data- excellent video as always!

  • @mattmarshall1834
    @mattmarshall1834 10 месяцев назад +2

    This was a great tutorial. You have a great presentation style. I had never heard of this UI framework until I randomly saw it here on your profile. Please do more with FastUI.

    • @bugbytes3923
      @bugbytes3923  10 месяцев назад +1

      Thanks a lot for the nice words! I'll need to get some more prepared for FastUI, for sure.

    • @mattmarshall1834
      @mattmarshall1834 10 месяцев назад

      @@bugbytes3923 It would be interesting to see it styled with Bootstrap.

  • @walterj89
    @walterj89 Год назад +6

    I'm really happy to see this project become a thing. I've been looking at how to add a simple UI on top of the API's I've been making in FastAPI. There just wasn't much that tied in well with FastAPI without reimplementing code for another framework.
    Essentially I was just getting into writing a Streamlet program that just calls the API from FastAPI behind the scenes. I wasn't the most thrilled with that solution. This is a much better direction.

  • @malteplath
    @malteplath Год назад +6

    Excellent video!
    I share the concern of abstraction overload: Using React to create a simple UI seems overkill, plus you are adding a whole ecosystem of unknown bugs/constraints.
    But as a reasonably simple interface for declarative definition of simple UIs, it looks very promising.

    • @bugbytes3923
      @bugbytes3923  Год назад +1

      Definitely a valid point, regarding abstraction overload.

  • @mikeckennedy
    @mikeckennedy Год назад +2

    Nice intro to something really different for python UIs.

    • @bugbytes3923
      @bugbytes3923  Год назад

      Thanks a lot! (Big fan of the podcast btw, awesome job!)

  • @seydinaoumarsamabaly1806
    @seydinaoumarsamabaly1806 Год назад +1

    Wow always surprising us with new stuffs. Thank you so much Master !

  • @dhariri
    @dhariri Год назад +14

    Very interesting. I wonder why they chose to be generating a React application as the underlying browser technology (and not just HTML and bound event handlers on the generated tags)

    • @Adrian_Galilea
      @Adrian_Galilea Год назад +2

      I guess because it's faster to do it this way in a manner that is both useful and easier to style. I would love it being HTMX but that would require much more human hours, no?

    • @code_ho
      @code_ho Год назад

      Depends on use cases and architecture you want to implement.

  • @losco_arti
    @losco_arti Год назад

    as always, best content I could find on the internet!

  • @TheAwaeng
    @TheAwaeng 11 месяцев назад

    that looks very promising !!

  •  Год назад

    Kudos to you dude, your videos are top quality.

    • @bugbytes3923
      @bugbytes3923  Год назад +1

      Thanks a lot for the nice comment, much appreciated!

  • @chrisrudy1969
    @chrisrudy1969 Год назад

    Very nice tutorial. Thank you!

  • @alexandremondaini
    @alexandremondaini 11 месяцев назад +1

    it would be nice to have a pagination example with db in the backend. so as the user clicks on the page a new query is issued per page on the db. If there is a lot of data how one would return a table effciently ?

  • @mastajigga13
    @mastajigga13 Год назад +1

    Yes, I'm very interest in this fastUI library. Please could you go and show us what it is capable of ?

  • @MCUlfang
    @MCUlfang Год назад +3

    Cannot import FormResponse because is not part of FastUI.forms no more

    • @TheSpinnybrook
      @TheSpinnybrook 10 месяцев назад

      Instead return c.FireEvent(event=GoToEvent(url="/endpoint"))

  • @artemshumeiko
    @artemshumeiko Год назад

    Great video! How do you find out about new libraries like this? Thanks

    • @bugbytes3923
      @bugbytes3923  Год назад +1

      Thank you! I typically look on Reddit and Twitter.
      This is a good resource to see what's trending too: github.com/explore

  • @robhafemeister3100
    @robhafemeister3100 Год назад

    Great video, looks promising.

  • @miriamramstudio3982
    @miriamramstudio3982 Год назад

    Great video. Thanks

  • @stannylou1636
    @stannylou1636 Год назад

    Great vid please do more on this FastUI like add css or something of that nature, thanks.

    • @bugbytes3923
      @bugbytes3923  Год назад +1

      Thanks a lot! Will add a new FastUI one tomorrow.

  • @pleabargain
    @pleabargain Год назад

    FWIW, I used GPT4 to rewrite the basic app to manipulate a different data set. Another video on how to digest a different API and generate a UI for that API would be very interesting.

  • @JOHNSMITH-ve3rq
    @JOHNSMITH-ve3rq Год назад

    Totes. I’d love to see the build of a sophisticated app with this.

    • @bugbytes3923
      @bugbytes3923  Год назад

      Thanks, will have a think about what we can do!

  • @itsfoss5268
    @itsfoss5268 Год назад +1

    Love it.

  • @suen-tech
    @suen-tech Год назад

    Thk you
    Excellent choice

  • @techinsider3611
    @techinsider3611 Год назад

    Great video . But i am watching Peaky Blinders now days so I enjoyed your accent as well 😂 What is this accent Scottish?

    • @bugbytes3923
      @bugbytes3923  Год назад +1

      Haha thank you - Peaky Blinders is great!
      Yes, from Glasgow, Scotland 😂

  • @VitthalGusinge
    @VitthalGusinge Год назад

    Can you cover SSE demo as well

    • @bugbytes3923
      @bugbytes3923  Год назад

      I'd like to add this, will try and schedule that into the plans.

  • @AmoahDevLabs
    @AmoahDevLabs Год назад +1

    Great one.

  • @phantompacketloss
    @phantompacketloss Год назад +1

    how does this compare to streamlit and others like it?

    • @JohnKabler
      @JohnKabler Год назад +1

      I have built many apps with streamlit for various prototypes. I'm currently working with fastUI on a new project.
      It's a bit apples and oranges. Streamlit has a very unique operating model with the code being re-executed with every user interaction. This uniqueness has the benefit of making the development pattern. Far more approachable for somebody that is only used to working in Jupyter notebooks. However, it's a closed garden and you can't just inject a little bit of streamlit into an existing code base. Also, I find the performance to be lacking.
      FastUI is not for somebody that only knows how to write pandas code in a notebook. If you're the kind of person that knows how to work on back end APIs, this thing is a killer. It integrates into an existing fast API app very easily. Performance is phenomenal. They did a very good job of making sure the react front end is nice and snappy. And you get the SSE out of the box!

  • @sigarlus
    @sigarlus Год назад

    HI, thanks for the introduction. I like fastapi. This is one of the missing pieces to get rid of Django easily.
    Is there a way to customize the bootstrap components?

    • @bugbytes3923
      @bugbytes3923  Год назад

      You can pass a "class_name" to components to customize the classes used (from Bootstrap, or custom CSS). I'm preparing another video which I'll release next week on database integration, will include a bit on styling!

    • @sigarlus
      @sigarlus Год назад

      @@bugbytes3923wow, answer on x-mass eve. I am impressed. Thanks mate!

  • @alexy.3512
    @alexy.3512 Год назад +3

    Interesting library, but that's about it. Going with HTMX, Phoenix Framework or Blazor makes more sense than a Python library that abstracts HTML even further by using.... React of all libraries.

  • @hoangphamkhanhnhat
    @hoangphamkhanhnhat 11 месяцев назад

    Thank you very much, the video is very nice.
    I just wondering that: When we type "localhost:8000/api/" to address bar of browser, can it show the page that we design instead of json or raw data?

    • @bugbytes3923
      @bugbytes3923  11 месяцев назад

      Thanks! Yes, you can show web pages at your URL routes.

    • @hoangphamkhanhnhat
      @hoangphamkhanhnhat 11 месяцев назад

      @@bugbytes3923 Thanks for your reply. I am very new in web development, so that would you please help me some hint to display the UI that I made with FastUI when user call an API (for example: localhost:8000/api/) on their web browser.

  • @cunningham.s_law
    @cunningham.s_law Год назад

    I wish I could just use jsx
    any babel equivalent in python or another transpiler that allows us to extend the syntax with a build step?

  • @samable9585
    @samable9585 4 месяца назад

    why not streamlit or taipy?

  • @fabsync
    @fabsync Год назад

    your videos are always great! It will be fantastic if you create a tutorial on django, postgres and flet like a todo app...!!

    • @bugbytes3923
      @bugbytes3923  Год назад +1

      Thanks a lot - will look into Flet asap!

    • @fabsync
      @fabsync Год назад

      Awesome! There is a huge following for flet alone and almost no good tutorials on that subject@@bugbytes3923

  • @paolinomarmolaro6308
    @paolinomarmolaro6308 Год назад

    The UI is very basic of course, how would you use this framework with a better UI?

  • @Ro1andDesign
    @Ro1andDesign Год назад

    Great video, FastUI has some potential. However basic functions like a multi-column layout seem to still be missing.

    • @bugbytes3923
      @bugbytes3923  Год назад

      It's very early stages so I expect more to be added. But you can attach classes to each component - so it's (probably) possible to create a multi-column structure with Bootstrap classes. Maybe an idea for another video!

  • @guruware8612
    @guruware8612 Год назад

    holy moly, a button!

  • @naranyala_dev
    @naranyala_dev Год назад

    is it like JSX? can we use HTMX on it or not?

  • @RocketLR
    @RocketLR Год назад

    isnt the point of react to not have to refresh the webpage for every click and action? :S

    • @szef_fabryki_azbestu
      @szef_fabryki_azbestu 11 месяцев назад

      And it doesn't (in FastUI). What I see in devtools is that page change downloads only new data in json format, not everything again.

  • @ahsin.shabbir
    @ahsin.shabbir Год назад

    what do you think of generate AI writing the front-end UI code for you so you don't need to do as much styling? There are multi-modal models that can take an image of a design and implement most of the html/css with good accuracy

  • @C0n3
    @C0n3 4 месяца назад

    If you knwo htm,css and jQuery for example, actually you don't need fast ui

    • @bugbytes3923
      @bugbytes3923  4 месяца назад

      True, it's more a tool to build simple webapps for people who aren't webdevs (data scientists, etc)

  • @Viralglobaltrends
    @Viralglobaltrends 8 месяцев назад

    Good approach but complicated syntax . Streamlit is bit easier for quick implementation .

  • @Septumsempra8818
    @Septumsempra8818 Год назад

    Wow

  • @pietraderdetective8953
    @pietraderdetective8953 Год назад

    Below is not meant to critic the video, but instead my view on general:
    I don't get the overall anti-JS mindset in the Python community...Javascript itself is not that hard, it's arguably the 2nd easiest programming language next to Python.
    1.5 year ago I started learning Python (I came from non-programming background), this year I learn Javascript. Now I can implement whatever (simple) JS I need for my webapp.
    No JS framework needed (avoid the JS framework hell), just use pure vanilla JS + HTML + vanilla CSS is more than enough.
    Also looking at FastUI official demo website, I think this will become like Bootstrap: everyone everywhere using the same template so everything looks similar.
    Great informative video though! can someone share FastUI project that showcase what a fullblown use of FastUI is capable of?

    • @bugbytes3923
      @bugbytes3923  Год назад +3

      Interesting perspective, thank you for sharing and the video suggestion!
      My own opinion (could be wrong) is that the Python community has a lot of programmers who are not necessarily web developers, but who want to build small apps for their work. For example - in the data/AI space - lots of developers and engineers who might prefer to spend their time elsewhere, rather than learning JS SPA frameworks or even building things out with JavaScript itself.
      This makes these options like HTMX and FastUI much more amenable - these tools can abstract away details and let the developer focus on the functionality in Python. However, if you're building enough web apps with enough complexity, then of course you'll be better served learning the underlying technologies like JavaScript/CSS etc.

    • @pietraderdetective8953
      @pietraderdetective8953 Год назад

      @@bugbytes3923 yes I agree I did use Bootstrap a lot on my early Python days and it did helped a lot to create a quick small/simple app...I think FastUI will achieve something similar: make it less painful / much easier to deal with frontend. So yeah it's ideal for people with not much interest on frontend stuff.
      The issue I got Bootstrap was too limiting / not flexible enough and most websites that use Bootstrap ends up looking similar --> this is my concern and hence why I asked if there's a project that showcases FastUI capabilities. If FastUI ends up being easy to use while maintaining flexibility and highly customizable --> this would be perfect ❤

    • @techinsider3611
      @techinsider3611 Год назад

      I would also be very happy with this video if i have seen it two years ago .
      I hated js and was running away from js.
      Then just learned it and now i do most of the things in js .
      But still miss python and try to use it whenever possible .
      It is not something against js it is just mindset difference between python and js .
      In js we have callbacks i did not understand those earlier .
      Now python also supports async await but the i dreaded those in js .
      Python and is are similar bcz they are dynamic but there philosophy is totally different .
      Python developer should try Svelte if they fear js .
      They will love it as i do now 😂

    • @BlueIced256
      @BlueIced256 Год назад

      @@bugbytes3923 I fully agree on that one! I am a data engineer and I use python a lot. Sometimes I need a quick web app to do some work like proof of concepts. I don't really care about learning all the web development stuff as it is not my job to create full-blown web applications. I think that FastUI is ideal for my purposes. Now I am usually building Rest API's and use Postman to load data for these purposes. But the problem there is that if users in the program have to work with Postman, then they are lost. Building a quick web app with FastUI will definitely be a game changer.

  • @danbailey9591
    @danbailey9591 Год назад

    Very similar to sqlpage.

  • @randomrainforest
    @randomrainforest 24 дня назад

    hi

  • @edhahaz
    @edhahaz Год назад

    Holy grail of dumpster fire

  • @osogrande4999
    @osogrande4999 Месяц назад

    Wow, yet more obscure half baked screwy ways to avoid JavaScript. Understandably so, JS is an abysmal joke of a language and the web “frameworks” hacked together in it are a sick one, but to see this nonsense bleeding into python is sad. Having said all that, fast UI, I haven’t looked at it but I can already tell it will be like filing my own teeth to do anything real world.

  • @hrznn
    @hrznn Год назад

    The sheer irony of Py developers calling their not fast things Fast(API)(UI). They're sipping that copium. (also notice how fast languages don't use fast in the name)

    • @bugbytes3923
      @bugbytes3923  Год назад +2

      It’s probably “fast enough” 😁

    • @kevon217
      @kevon217 Год назад +2

      end game is FastPython

    • @chukwujekwuchiaha6605
      @chukwujekwuchiaha6605 Год назад +2

      That's right! FastAPI + FastUI = FastPython for everything mobile, web and desktop. PERIOD!!!

    • @dandradejose
      @dandradejose Год назад

      Fast solutions with little coding

    • @MariusHeier1
      @MariusHeier1 11 месяцев назад

      Its fast dev not fast execution