Skip to content

Commit

Permalink
Enhance feature documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
hvelarde committed Sep 28, 2017
1 parent 6d9352c commit 870c37b
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 11 deletions.
5 changes: 3 additions & 2 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ There's a frood who really knows where his towel is.
2.12b2 (unreleased)
^^^^^^^^^^^^^^^^^^^

- Implement prefetch for Facebook.
[claytonc]
- Implement Facebook prefetching.
Check package documentation for more information on how to use this new feature (closes `#129 <https://github.com/collective/sc.social.like/issues/129>`_).
[claytonc, hvelarde]

- Add Open Graph fallback image for content lacking lead image;
the image should be uploaded in the control panel configlet and must comply with best practices;
Expand Down
20 changes: 14 additions & 6 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -107,19 +107,27 @@ For more information see:

You can disable content validation using an option in the control panel configlet.

Prefetching Facebook
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Facebook prefetch
^^^^^^^^^^^^^^^^^

.. note::
This feature is only available for Dexterity-based content types.

Prefetching allows Facebook to download mobile content before someone clicks a link.
When content is shared for the first time,
the Facebook crawler will scrape and cache the metadata from the URL shared.
The crawler has to see images at least once before they can be rendered.
Prefetching allows Facebook to download content before someone shares it.

Prefetching is especially beneficial for people using Facebook on slow or poor network connections.
According to `Facebook's documentation <https://www.facebook.com/business/help/1514372351922333>`_,
prefetching is especially beneficial for people using Facebook on slow or poor network connections.
Prefetching also loads mobile site content faster,
which improves the Facebook app experience on Android and iPhone devices.

According to Facebook's `documentation <https://www.facebook.com/business/help/1514372351922333>`_:
You can enable Facebook prefetch using an option in the control panel configlet.

The default is disable, but you can enable prefetch using an option in the control panel configlet.
A call to the Graph API endpoint will be generated automatically every time a new piece content is published,
and every time a published content is edited.
This will keep the metadata updated on Facebook always.

Canonical URL and migration to HTTPS
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Expand Down
9 changes: 6 additions & 3 deletions sc/social/like/interfaces.py
Original file line number Diff line number Diff line change
Expand Up @@ -225,11 +225,14 @@ class ISocialLikeSettings(model.Schema):
)

facebook_prefetch_enabled = schema.Bool(
title=_(u'Enable Prefetching Facebook?'),
title=_(u'Enable Facebook prefetch?'),
description=_(
u'help_facebook_prefetch_enabled',
default=u'If enabled, an event is triggered so that Facebook '
u'downloads mobile content before someone clicks on a link.'
default=u'If enabled, an event is triggered to make Facebook '
u'crawler scrape and cache metadata every time a new '
u'piece content is published and every time published '
u'content is edited. '
u'This will keep the metadata updated on Facebook always.'
),
default=False,
)
Expand Down

0 comments on commit 870c37b

Please sign in to comment.