question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

RFC: Should we drop JSX support? 🤪🤯

See original GitHub issue

EDIT: Thank you everyone for your enormous feedback! For the looks of it, a lot of people around here don’t use or don’t care about JSX or are ready to learn better ways! 😏🙏

Good for us for you! I mean it. I think I am not ready to remove JSX from core and start asking people to get a dependency to support JSX. For every comment and thumbs up, there are more lurking eyes and thumbs that go unnnoticed and I am willing to bet they don’t hold the same courageous opinion.

I feel that I would end up alienating and disuniting more than uniting with a move like this. So, I am happy to close this. 🎉


Should we drop built-in JSX support? Yes or No?

This involves modifying (simplifying really) how hyperapp.h works, by making it monomorphic (single signature) instead of the current implementation that supports multiple varargs (arguments are slow!).

Pros

  • Better performance.
  • More liberty in how components are used / instantiated.

Cons

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:23
  • Comments:19 (11 by maintainers)

github_iconTop GitHub Comments

11reactions
ludoviclafolecommented, Nov 26, 2017

I use JSX with hyperapp but, reading all the discussion it seems pretty easy to support on userland. Perhaps document how to use JSX for those that are interested in it ?

So for me nothing against dropping it 👍

9reactions
lukejacksonncommented, Nov 23, 2017

I’ve always found that JSX detracts from the simplicity and purity of hyperapp somewhat. We are pursuing and encouraging, to a degree, a pure and functional approach to building apps. JSX obfuscates and kind of contradicts this intention. WYSIWYG code is good, vanilla JavaScript is good and functions… are good.

  • It is a proprietary markup language
  • Another thing to learn
  • Demands compilation
  • Messes with syntax highlighting
  • Less terse thanh syntax
  • Negatively impacts performance
  • Limits the potential of component progression
  • It is another way of doing the same thing

We are not alone in doubting it’s usefulness https://news.ycombinator.com/item?id=11290827

As you know, I hate typing and boilerplate… so I like to imagine how things scale where there are 10 of something for instance, props:

<Component propA={propA} propB={propB} propC={propC} propC={propC} propD={propD} propE={propE} propF={propF}/>

When you can do exactly they same, with just vanilla JS:

Component({ propA, propB, propC, propD, propE, propF })

There are, of course, more intricate niggles and inconsistencies like className etc. but we are all aware of these so I won’t list them.

$0.02

Read more comments on GitHub >

github_iconTop Results From Across the Web

Introducing the React RFC Process – React Blog
RFCs are accepted when they are approved for implementation in React. A more thorough description of the process is available in the ...
Read more >
React 18, React-Native 0.68, Redwood 1.0, Remix, Next.js ...
This new version offers many improvements and APIs that we have already talked about: automatic batching, SSR streaming, Suspense, selective ...
Read more >
Theo - t3.gg on Twitter: "WHY DID NOBODY TELL ME THE ...
WHY DID NOBODY TELL ME THE ASYNC/AWAIT REACT RFC DROPPED ... RFC: First class support for promises and async/await by acdlite · Pull...
Read more >
Make use of `use` in React - a new hook is coming - Vived
First class support for Promises in React. Every React RFC ... Looking at the title of the new RFC you may wonder what...
Read more >
RFC 3261 SIP: Session Initiation Protocol - IETF
SIP makes use of elements called proxy servers to help route requests to the ... (We shall see in the next section how...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found