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.

Support (or document non-support) for Fragments

See original GitHub issue

https://github.com/reactjs/reactjs.org/pull/345

React is adding a top-level React.Fragment export that transpiles to JSX as:

<>
  <li>Stuff</li>
  <li>Things</li>
</>

React.createElement(React.Fragment, {}, ...)

Would Preact be able to support fragments or provide some type of fallback?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:90
  • Comments:41 (18 by maintainers)

github_iconTop GitHub Comments

44reactions
marvinhagemeistercommented, Aug 24, 2018

No, current preact expects a DOM node per vnode. This is not true for Fragments where the whole point of them is to not render anything into the DOM. So this is not easily doable (if at all) with the current architecture.

That said we have merged the PR for Fragments into our development repo last week. Fragments will be part of the next major release🎉

It is not available to the public yet and we don’t have a release estimate for now. It’s progressing nicely and we are currently working through an ever shrinking number of failing test cases and ensuring that all known bugs in the next version are fixed.

37reactions
marvinhagemeistercommented, Mar 28, 2018

@georgiemathews We do have Fragments working in a private branch, but we haven’t had the time to make it work with hydration yet.

Read more comments on GitHub >

github_iconTop Results From Across the Web

getSupportFragmentManager().getFragments() deprecated?
Furthermore, I cannot find this method in the android documentation for either the support fragment manager and the non-support one.
Read more >
Text fragments - MDN Web Docs - Mozilla
Text Fragments allow you to link directly to a specific portion of text in a web document, without requiring the author to annotate...
Read more >
Revised Statutes of Missouri, RSMo Section 568.040 - MO.gov
568.040. Criminal nonsupport, penalty — definitions — payment of support as a condition of parole — expungement of records, when — prosecuting attorneys...
Read more >
Possible Ajax Loop Bug | WordPress.org
load_fragments () amongst other things triggers $(document).trigger( 'yith_wcwl_fragments_loaded' ... and hopefully this will help you solve your problem too.
Read more >
A User is Not Able to Link Multiple Documents to Approved ...
The Vault document relationship that is used to link a document to an email fragment allows for only one document to be linked...
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