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

Improve Story Discoverability on Frontend #2191

Merged
merged 5 commits into from
Jun 4, 2020
Merged

Improve Story Discoverability on Frontend #2191

merged 5 commits into from
Jun 4, 2020

Conversation

swissspidy
Copy link
Collaborator

Summary

Sharing stories should render nice previews out of the box. This PR adds Open Graph & Twitter card output to achieve this.

Relevant Technical Choices

Adds a dedicated Discovery class that deals with anything related to <head> metadata and such.

To-do

User-facing changes

Testing Instructions


Addresses #1117

@swissspidy swissspidy added Type: Enhancement New feature or improvement of an existing feature Group: Discoverability Pod: WP & Infra labels Jun 2, 2020
@swissspidy swissspidy changed the title Add/discovery Improve Story Discoverability on Frontend Jun 2, 2020
@codecov
Copy link

codecov bot commented Jun 2, 2020

Codecov Report

Merging #2191 into master will decrease coverage by 0.02%.
The diff coverage is 65.62%.

Impacted file tree graph

@@             Coverage Diff              @@
##             master    #2191      +/-   ##
============================================
- Coverage     66.16%   66.13%   -0.03%     
- Complexity      296      305       +9     
============================================
  Files           640      641       +1     
  Lines         10474    10504      +30     
============================================
+ Hits           6930     6947      +17     
- Misses         3544     3557      +13     
Impacted Files Coverage Δ Complexity Δ
includes/Plugin.php 0.00% <0.00%> (ø) 7.00 <0.00> (ø)
includes/Discovery.php 58.00% <58.00%> (ø) 33.00 <33.00> (?)
includes/Media.php 87.50% <100.00%> (+3.16%) 27.00 <9.00> (+9.00)
includes/REST_API/Stories_Controller.php 70.14% <100.00%> (ø) 42.00 <0.00> (ø)
includes/Story_Post_Type.php 60.91% <100.00%> (-2.13%) 39.00 <0.00> (-33.00)
includes/Story_Renderer.php 90.16% <100.00%> (ø) 17.00 <0.00> (ø)
...ts/src/dashboard/components/pageStructure/index.js 76.92% <0.00%> (-3.08%) 0.00% <0.00%> (ø%)
includes/Dashboard.php 80.00% <0.00%> (ø) 13.00% <0.00%> (ø%)
assets/src/dashboard/constants/index.js 100.00% <0.00%> (ø) 0.00% <0.00%> (ø%)

@github-actions
Copy link
Contributor

github-actions bot commented Jun 2, 2020

Size Change: +61 B (0%)

Total Size: 806 kB

Filename Size Change
assets/js/stories-dashboard.js 421 kB +61 B (0%)
ℹ️ View Unchanged
Filename Size Change
assets/css/edit-story.css 269 B 0 B
assets/css/stories-dashboard.css 305 B 0 B
assets/css/web-stories-embed-block.css 501 B 0 B
assets/js/edit-story.js 368 kB 0 B
assets/js/web-stories-embed-block.js 15.7 kB 0 B

compressed-size-action

includes/Discovery.php Outdated Show resolved Hide resolved
includes/Discovery.php Outdated Show resolved Hide resolved
includes/Discovery.php Outdated Show resolved Hide resolved
@spacedmonkey
Copy link
Contributor

Do you think we have enough filters to intergrate with say yoast or jetpack seo tools?

@spacedmonkey
Copy link
Contributor

Related: Yoast/wordpress-seo#13446 #113

@swissspidy
Copy link
Collaborator Author

Do you think we have enough filters to intergrate with say yoast or jetpack seo tools?

For now, I think so. But only by collaborating with Yoast & others and putting this out into the wild we'll know for sure. That's what the beta will be useful for.

@swissspidy swissspidy marked this pull request as ready for review June 3, 2020 12:28
@swissspidy swissspidy requested a review from spacedmonkey June 3, 2020 12:28
Copy link
Contributor

@spacedmonkey spacedmonkey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There were a couple of things as nitpicks, but nothing that really blocks this being merged.

@swissspidy swissspidy merged commit a4caabd into master Jun 4, 2020
@swissspidy swissspidy deleted the add/discovery branch June 4, 2020 13:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Group: Discoverability Type: Enhancement New feature or improvement of an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants