Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider using Preact for Gutenberg rendering #2732

Conversation

adamsilverstein
Copy link
Member

@adamsilverstein adamsilverstein commented Sep 15, 2017

Preact is a minimal, MIT license and largely compatible with the React API. It philosophy seems to align well with that of WordPress, we should consider using it in light of recent licensing decisions.

note: this is a WIP and doesn't actually work yet :)

@youknowriad
Copy link
Contributor

@itzikbenh
Copy link

Do you have any clue if Preact is using the React Virtual DOM in some way? If so then this still might bound Preact users to the React patent clause in case FB holds patents on the Virtual Dom.

Either way, due to mainly Laravel there's a big PHP community behind Vue and I think that would be the wise choice. We should think long term, a couple of weeks here or there won't make a difference.

@youknowriad
Copy link
Contributor

youknowriad commented Sep 15, 2017

Do you have any clue if Preact is using the React Virtual DOM in some way?

I'm pretty confident with the preact code source and it does not use anything from React. It diffs DOM against virtual elements, while React's virtual dom is diffing virtual elements together (same thing for Vue.JS) aside its outside API. So I'd argue that Vue is more bound to any React's patent than preact.

@itzikbenh
Copy link

So I'd argue that Vue is more bound to any React's patent than preact

I see. I still would go with Vue. On the worst case Vue will have to change a bit to avoid patent problems, if there are any.
Also, Vue has more tooling and much bigger community. That itself should be a good enough reason to choose it.

@tyaakow
Copy link

tyaakow commented Sep 15, 2017

Vue.JS has superb documentation, it is mature, it has mature ecosystem built around it, very gentle learning curve, you reach productivity very fast, license is friendly, and benchmarks are in its favor

21457706_1856857884330769_8960087510078305761_o

@ntwb
Copy link
Member

ntwb commented Sep 15, 2017

This is a PR switching from React to Preact, discussing the merits of Vue vs Preact is out of scope

Fragmenting discussions in multiple places is not helpful for the team or the contributors to previous and existing ongoing discussions, please, and thank you 😄

Discussion should continue in public on the the make / core P2:
https://make.wordpress.org/core/2017/05/24/javascript-chat-summary-for-may-23rd/
https://make.wordpress.org/core/2017/05/31/javascript-chat-summary-for-may-30th/

@adamsilverstein
Copy link
Member Author

see https://github.com/WordPress/gutenberg/tree/try/preact

@youknowriad Ah, thanks for pointing that out, I did try searching for similar work before opening the PR. Glad to see work already happening exploring the option, I'll check out the branch and close my PR :)

Closing in favor of #2734

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants