Automattic / wp-calypso

The JavaScript and API powered WordPress.com
https://developer.wordpress.com
GNU General Public License v2.0
12.41k stars 1.99k forks source link

Premium content: use new context API server-side #41744

Open artpi opened 4 years ago

artpi commented 4 years ago

Currently, Premium Content block uses convoluted methods of passing data between the container block and inner logged-out view

The new usage of context could help: https://github.com/WordPress/gutenberg/pull/21467

Usage of recursion: https://github.com/WordPress/gutenberg/blob/master/packages/block-library/src/navigation/index.php

artpi commented 4 years ago

CC @eoigal

artpi commented 4 years ago

The terrible solution we want to replace is https://github.com/Automattic/wp-calypso/blob/master/apps/full-site-editing/full-site-editing-plugin/premium-content/premium-content.php#L154

github-actions[bot] commented 3 years ago

This issue is stale because it has been 180 days with no activity. You can keep the issue open by adding a comment. If you do, please provide additional context and explain why you’d like it to remain open. You can also close the issue yourself — if you do, please add a brief explanation and apply one of relevant issue close labels.