5

So on January 16th I started building a web app python+flask
It's going along pretty good
But now I feel it needs a lil bit of that on the UI side like pop-ups etc

And wanted to ask more experienced devs out there
Which framework is better and easy to integrate with my app

→ Angular
→ JQuery
→ React

I've already downloaded books on all of these

Comments
  • 3
    Angular is the only framework in that list. Angular elements would be my choice for most things because I like flexibility with good defaults, testing and type checking ootb.

    React will be the simplest, but require more plumbing. Use this if you only need to add views and basic routes.

    jQuery should be legacy only.

    Better and easy isn't an intersection that exists.
  • 2
    Vue is the best compromise between easy and good
  • 1
    If it has to be another "does not work without JavaScript" website, at least try out Vanilla JavaScript. It is pretty lightweight and can do a lot of things.
  • 2
    Honestly I don't get the crap jQuery gets. It's not legacy. For example jQuery really out performs the vanilla "framework". It doesn't crash all the time a freaking element does not exist and is readable while having almost no overhead in real world application.

    If you need to do some Dom manipulation use jQuery, it's still the best for that.
    If you go the react way, take a look at mobx before you go redux.
  • 2
    @hjk101

    That sentiment is dangerously stuck in the past.

    - all the Dom manipulation, traversal and query is vanilla now, it's not "the best for that" anymore in any sense
    - $ajax is replaced by fetch, xmlhttprequest at worst
    - jQuery has no update cycle coordination, so at any significant number if jQuery managed elements in the DOM you run the risk of forced repaints and layout thrashing and poor performance
    - contributing to the previous, no two things in jQuery are aware of each other, everything is an island. Because of this, two instructions querying the global DOM can collide, and there's no single ownership
    - there's no compile time support for jquery in regards to how it interacts with the DOM, so you end up passing strings as templates routinely (no AST)
    - traversal performance is 4x slower than native, on its best day
    - animation performance is awful, doesn't use modern features and competes with css animations
    - people lean into plugins, so you end up with version competition
    - it doesn't respect the modules paradigm, which leads to duplication

    It was designed as an all the things polyfill for browser differences in the "bad parts" era. John Resig did amazing work, so amazing that the things he did shaped what is now. jQuery is 30kb your site just doesn't need anymore.
  • 1
    I'd say start with simple jQuery and when you want to move to more sophisticated frontend, move to React/VueJs. As a primarily Python backend guy, I prefer using VueJs as creating a hierarchy of components and the event handling is a bit simpler
  • 1
    Thank you all for your contribution/advice/suggestions/enlightenment

    From the looks of things:
    ↓JQuery
    ↑React
    ↑VueJs
    ↑Vanilla
  • 0
    @SortOfTested well I have a lot of faith in your as you are one of the more knowledgeable people on the planet.

    I have not looked at it since vanilla was all the rage about a year or two ago. Have not done any new jQuery projects since then either. As you can see on http://youmightnotneedjquery.com/ things just require far less and more concise code in jQuery. Every performance comparison was horribly in favour of vanilla. I could optimize the examples in a minute and have negligible performance difference. (Couldn't find the article and jsfiddle on slack anymore sorry). We have a large customer base on ie11 but that is finally going down a bit. So if I evaluate it again I might completely agree with you!

    And of course as with JS you have to avoid the bad parts/plugins.
  • 1
    @hjk101
    I've suffered a lot, and share my pain for free 😉.

    The IE bit is your technical debt coming back to haunt you. Microsoft is consistent on it's messaging that IE isn't a browser, it's a compatibility solution for code that cannot change.

    The flip side of that message is, if you can't get them on at least Edge chromium, you will be obliged to continue digging yourself deeper.

    https://techcommunity.microsoft.com/...
  • 1
    Such a question with so many good response
    It only got 1 ++

    Typical lyf of a Dev :-D

    Develop a system that generates thousands and yu only get a tap on the shoulder
  • 1
    @SortOfTested The government and hospitals. Need I say more. Recently read something about New Jersey requiring COBOL programmers so I guess we are quite advanced here.
  • 1
    @hjk101
    Yeah, used to live in Jersey City, I feel you. 👍
Add Comment