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.

Thinking about React 15 support

See original GitHub issue

I’d like to help contribute migrating this project to React 15, and I think we could greatly reduce the amount of code necessary. For instance, right now the code is doing a ton of dependency injection since we don’t have screen in scope. What if this library looked something like this instead?

import React, { Component } from 'react';
import blessed from 'blessed';
import { Element, Box, render } from 'react-blessed';

export default class TerminalApp extends Component {
  render() {
    return (
      <Element>
        <Box width="100%" height="50%" top="0%">Top</Box>
        <Box width="100%" height="50%" top="50%">Bottom</Box>
      </Element>
    );
  }
}

const screen = blessed.screen({
  autoPadding: true,
  smartCSR: true,
});

render(<TerminalApp />, screen);

Issue Analytics

  • State:open
  • Created 7 years ago
  • Reactions:17
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
DxCxcommented, Jul 17, 2017

hey @tbranyen any update on this?

0reactions
Yomguitherealcommented, Jan 26, 2018

If you have some tips on how to preload React with those components so it works like react-dom does.

I don’t understand what you mean. This is already the case. Tou don’t have to “preload” the components, they are not components but primitives.

Read more comments on GitHub >

github_iconTop Results From Across the Web

React v15.0 – React Blog
React 15 brings significant improvements to how we interact with the DOM: ... We heard you, and in React 15 we added support...
Read more >
React For Everyone #7.5 - Updating to React 15 - YouTube
In this React video tutorial, we actually create a filter using our input. Subscribe for more free tutorials https://goo.gl/6ljoFc, ...
Read more >
Chapter 15 Introduction to React | Client-Side Web Development
See the documentation article Thinking in React for an example of how to design a ... One of the main goals of using...
Read more >
Notes on upgrading from React 15 to 16 - GitHub
Think of error boundaries like try-catch statements, but for React components. Portals. Portals provide a first-class way to render children into a DOM...
Read more >
React (JavaScript library) - Wikipedia
React is a free and open-source front-end JavaScript library for building user interfaces based on UI components. It is maintained by Meta (formerly ......
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