Repository navigation
Description
Feature Description
With the catalog datastore in place, this issue populates it: an entry for every feature in the MVP catalog, carrying that feature's final copy.
The features list is the source of truth for all of that copy — note that some of the copy in Figma is placeholder text — and for the mapping of features to goal categories. Site Kit's own features are registered centrally, while a feature belonging to a module is registered by that module, so each entry sits with the code that activates it.
Two features in the features list are out of scope for this iteration and so are not registered, even though the Figma design shows cards for them: Consent Mode, which has no setup surface for the hub to point at yet, and Reader Revenue Manager's sub-features other than the newsletter sign-up form, which its express setup flow doesn't cover yet.
For reference, see the The feature catalog & datastore and The full catalog sections in the design doc, and the All services and features design in Figma.
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance criteria
- The catalog registers an entry for each of the following features:
- Analytics
- Ads
- AdSense
- PageSpeed Insights
- Sign in with Google
- Newsletter sign-up form (Reader Revenue Manager)
- Reader Revenue Manager (full setup)
- Enhanced measurement
- Ad blocker detection
- Visitor groups
- Key Metrics
- Dashboard sharing
- Email reports
- PDF report
- Each entry's copy is taken verbatim from the features list, which is the source of truth for it: the card's title and short description, its setup effort, its CTA label, its badges, the detail panel's description / requirements / screenshots content, and the copy for its success notice. All of it is translatable.
- Screenshots are taken from the screenshot gallery in Figma. If any screenshot is not available yet, use a placeholder and we'll address it in a followup issue when the screenshot becomes available.
- Each entry is mapped to its goal categories per the features list. The first is the category the feature's card appears under; the rest only affect filtering.
- Each entry records the Site Kit version its feature was released in.
analytics-4is a prerequisite module for Enhanced measurement, Visitor groups and Key Metrics, andadsenseis a prerequisite for Ad blocker detection. No other MVP feature has a prerequisite module.- The newsletter sign-up form entry is only registered when the
rrmExpressSetupfeature flag is enabled, and the PDF report entry only when thepdfGenerationfeature flag is enabled. If either flag has been retired by the time this is built, its entry is registered unconditionally. - Consent Mode is not registered, and neither are Reader Revenue Manager's other sub-features — surveys, paywalls, contributions and rewarded ads. All of them are out of scope for this iteration.
- This issue covers the catalog's content only. The activation mechanics behind each entry's CTA are out of scope.
Implementation Brief
- In
webpack/common.js- Update
svgRuleto add a resource query tooneOfto support importing SVGs as URL paths by appending?path.
- Update
{
resourceQuery: /path/,
type: 'asset/resource',
generator: {
filename: 'images/[name]-[contenthash][ext]',
},
},- In
assets/js/types/svg.d.ts- Declare a module for
.svg?path.
- Declare a module for
declare module '*.svg?path' {
const content: string;
export default content;
}- In
assets/js/googlesitekit/datastore/feature-discovery/constants.ts- Define a
FEATURE_BADGESconstant with at least `PAID_SERVICE: 'paid-service' for now.
- Define a
- Create
assets/js/googlesitekit/feature-discovery/index.ts:- Export a
createFeatureDiscovery( registry )method that accepts a data registry and returns aFeatureDiscoveryobject with aregisterFeaturemethod that dispatchsregisterFeaturefromCORE_FEATURE_DISCOVERYwith matching parameters (seeassets/js/googlesitekit/widgets/index.jsfor an example of this pattern). - Export
FeatureDiscovery.
- Export a
- Create
assets/js/googlesitekit/feature-discovery/register-defaults.ts:- Export a
registerFeatureDiscovery( featureDiscovery )method that accepts aFeatureDiscoveryAPI object and registers each SK feature from the spreadsheet as follows. The datastore from Add thecore/feature-discoverydatastore — registration & core selectors #13245 may need to be updated so that the expected shape ofsettings.detailmatches the example below. addedInVersionwill need to be determined during execution as a list doesn't currently exist. The Git history,changelog.txtand the feature flags sheet are resources available. When identified, add the added version to the feature list sheet.- For screenshots, use SVGs where available and optimise with https://svgomg.net/. Import using the
.svg?pathresource query implemented above to get a URL that can be passed to an<img>tag.
- Export a
import screenshotURL from './path/to/screenshot.png'; // Add `?path` to path if using .svg images.
featureDiscovery.registerFeature(
'feature-slug',
{
title: __( '', 'google-site-kit' ), // Refer to spreadsheet. "Short description" column, bold text.
shortDescription: __( '', 'google-site-kit' ), // Refer to spreadsheet. "Short description" column, after the bold text.
effort: 1, // Refer to spreadsheet. "Setup Difficulty" column. Use `FEATURE_EFFORTS` constants.
prerequisiteModules: [''], // Refer to AC for features with prerequisite modules. Use `MODULE_SLUG_*` constants.
goalCategories: [''], // Refer to spreadsheet. "Feature categories" tab. Use `FEATURE_CATEGORIES` constants.
addedInVersion: '',
setup: {
type: '', // Refer to the full catalog in the design doc. Use `FEATURE_SETUP_TYPES` constants.
ctaLabel: __( '', 'google-site-kit' ), // Refer to spreadsheet. "setup CTA button in panel" column.
},
detail: {
description: {
whatIs: __( '', 'google-site-kit' ), // Refer to spreadsheet. "What is this feature?" column.
whyUseHeading: __( '', 'google-site-kit' ), // Refer to spreadsheet. Bold text in the "Why use [feature/service name]" column.
whyUseList: [ // Refer to spreadsheet. List items in the "Why use [feature/service name]" column.
{
term: __( '', 'google-site-kit' ), // Text before : in each item.
description: __( '', 'google-site-kit' ), // Text after : in each item.
},
],
},
requirements: {
serviceRequirements: __( '', 'google-site-kit' ), // Refer to spreadsheet. "Service requirements" column.
setupList: [ // Refer to spreadsheet. List items in "Setup checklist" column.
__( '', 'google-site-kit' ),
__( '', 'google-site-kit' ),
],
setupComplete: __( '', 'google-site-kit' ), // Refer to spreadsheet. Paragraph after list items in "Setup checklist" column.
},
screenshots: [ // Refer to spreadsheet. "Screenshots list" column.
{
alt: __( '', 'google-site-kit' ), // A description of the screenshot.
height: 900, // The natural height of the screenshot in pixels.
src: screenshotURL, // Image from the Figma screenshot gallery matching the description, or a placeholder.
width: 1440, // The natural width of the screenshot in pixels.
},
],
},
badges: [], // Refer to spreadsheet. "Badges" column. Use `FEATURE_BADGES` constants.
successNotice: { // Refer to spreadsheet. "Success notice" column.
title: __( '', 'google-site-kit' ), // Bold text.
description: __( '', 'google-site-kit' ), // After the bold text.
cta: {
label: __( '', 'google-site-kit' ), // Bold CTA text.
dismissLabel: __( '', 'google-site-kit' ), // Other CTA text. Can be omitted for the default "Got it".
}
},
}
);- Create
assets/js/googlesitekit-feature-discovery.ts:- Import and call
createFeatureDiscoverywithData from 'googlesitekit-data', and assign toFeatureDiscovery. - Import
registerFeatureDiscoveryfromregister-defaults.tsand call it withFeatureDiscovery. - Assign
FeatureDiscoverytoglobal.googlesitekit.featureDiscoveryif it's undefined.
- Import and call
- Update the following to set up
googlesitekit-feature-discoveryas an entry point (copy implementation ofgooglesitekit-widgetsandgooglesitekit-notifications):.eslintrc.jsontsconfig.jsonassets/webpack/modules.config.jsincludes/Core/Assets/Assets.phpwebpack/common.js
- Create a
features/index.tsfor each module that exports aregisterFeatureDiscovery( featureDiscovery )function that registers the module's features:assets/js/modules/ads/assets/js/modules/adsense/assets/js/modules/analytics-4/assets/js/modules/pagespeed-insights/assets/js/modules/reader-revenue-manager/assets/js/modules/sign-in-with-google/
- In each of the following import each module's
registerFeatureDiscoveryand call it withFeatureDiscovery from 'googlesitekit-feature-discovery'.assets/js/googlesitekit-modules-ads.tsassets/js/googlesitekit-modules-adsense.tsassets/js/googlesitekit-modules-analytics-4.tsassets/js/googlesitekit-modules-pagespeed-insights.tsassets/js/googlesitekit-modules-reader-revenue-manager.tsassets/js/googlesitekit-modules-sign-in-with-google.ts
Test Coverage
- Add test coverage for
createFeatureDiscoveryensuring that it can be properly used to register features.
QA Brief
-
Make sure
featureDiscoveryHub,pdfGenerationandrrmExpressSetupflags are enabled in the tester plugin. -
Setup the SK plugin.
-
Run following command and make sure it outputs
14features as list shown in the screenshot.const { dispatch, select } = googlesitekit.data; const FD = "core/feature-discovery"; select(FD) .getFeatures() .map((feature) => feature.slug);
-
Run following command one by one, only replacing the feature slug.
const { dispatch, select } = googlesitekit.data; const FD = "core/feature-discovery"; const featureDetails = select(FD).getFeature("ads"); // `ads` is the feature slug here. console.log(featureDetails); console.log("Title", featureDetails.title); console.log("Short description", featureDetails.shortDescription); console.log( "Full description - whatIs", featureDetails.detail.description.whatIs, ); console.log( "Full description - Why use", featureDetails.detail.description.whyUseHeading, ); console.log( "Short description - Why use list", featureDetails.detail.description.whyUseList, ); console.log( "serviceRequirements", featureDetails.detail.requirements.serviceRequirements, ); console.log("setupList", featureDetails.detail.requirements.setupList); console.log("Effort", featureDetails.effort); console.log("Goal categories", featureDetails.goalCategories); console.log("Setup CTA label", featureDetails.setup.ctaLabel); console.log("Setup module slug", featureDetails.setup.moduleSlug); console.log("Setup type", featureDetails.setup.type); console.log( "Success Notice CTA description", featureDetails.successNotice.description, ); console.log("Success Notice CTA title", featureDetails.successNotice.title); console.log( "Success Notice CTA dismissLabel", featureDetails.successNotice.dismissLabel, );
-
Verify the copy matches the one given in feature details sheet in AC.
Changelog entry
- Register the feature catalog for the Feature Discovery Hub.
Activity
JakePT commentedon Aug 12, 2026
@techanvil Just wanted to check a few things here:
assets/js/modules/analytics-4/features-discovery.ts?assets/js/feature-discovery/register-defaults.tsimports those files and registers them withregisterFeature, alongside base plugin features?checkRequirements()?registerFeature()within itself? The design doc implies this main file imports the module files directly.featuresAPI.registerFeature()like how notifications works inassets/js/googlesitekit/notifications/register-defaults.jsandassets/js/modules/ads/notifications/index.js? I don't see anything like that on Add thecore/feature-discoverydatastore — registration & core selectors #13245. Is that even part of the scope of this issue, or should this just focus on exporting definitions for now?settings.detail.descriptionandsettings.detail.requirementsjust JSX? Does each feature's description need to include the full "What" and "Why" headings and markup?createInterpolateElementfor rendering, so the feature only needs to own'<what /><p>My description</p>and we can inject the heading and<P>typography component later? Or should the what and why sections be split up into separate fields? I'm concerned about these owning a bit too much of their presentation.techanvil commentedon Aug 12, 2026
Hi @JakePT, thanks for checking these things.
Please follow the same approach as the notifications framework, and ignore where the design doc says that
feature-discovery/register-defaults.tswill import from each module'sfeatures-discovery.tsfile. This detail is an artifact I missed in a recent update (the original intent was to follow the notifications pattern, this was changed to enable the global count bundle that was considered but rejected), and should have been reverted. Sorry for the confusion.Each module should call
registerFeature()itself, and the work to exposefeaturesAPI.registerFeature()etc is within the scope of this issue.The feature's
descriptionandrequirementsfields should simply be strings, ideally. Feel free to tweak the data model to accommodate this - we can track any significant changes in the changes during engineering section of the design doc.Screenshots should be lazy imports, following existing conventions for lazy loading images.
JakePT commentedon Aug 14, 2026
@techanvil Thanks, I think I've finished the IB. Some notes:
settings.detailto the changes section of the design doc with a link to this issue.screenshots.techanvil commentedon Aug 17, 2026
Hi @JakePT - thanks for drafting this IB, which is looking good. A few points:
goalCategories.addedInVersion, as it could be interpreted to mean we'll determine these in a subsequent issue.lazy()call in the feature definition. We won't need theheightandwidthproperties for SVGs.badgeswon't be entirely empty for now - the Ads feature has the "Paid service" badge, as seen in Figma (note that the "Recommended for you" badges are not in scope for FDH v0, they are tied to the "Suggested for you" tab that we'll add in v1). I've added a Badges column in the features sheet to help track this.44 remaining items
kelvinballoo commentedon Sep 10, 2026
QA Update⚠️
Thanks @ankitrox
For ITEM 2, yes, I ran the whole script and the PDF feature flag is on. Noting that I also faced this error for
Reader Revenue Manager (full setup)Details
I also have more observations as I complete my testing:
ITEM 4: Wrong effort
I noted the following efforts which were wrongly set:
ITEM 5:
For 'Ad blocker detection', the function is actually 'Ad block recovery'.
I'm wondering if we should change the phrasing from 'Ad blocker detection' to 'Ad block recovery' to have a consistent language?
ITEM 6:
For Key metrics:
There is a Copy typo for the full description: 'highlighing ' should be 'highlighting'
In the
Why use key metrics?section, the order of the team-alignment is not the same as the spreadsheet: 2nd position vs 4th positionDetails
JakePT commentedon Sep 15, 2026
@ankitrox @techanvil Just flagging something I ran into on #13359. The RRM express setup feature uses
n.e.x.tforaddedVersionin the catalog, but this causesisFeatureNewto throw an error and break the badge. We'll need to use something else for unreleased features, dynamically replace that value when registering a feature insideregisterFeature(), or catch it withinisFeatureNewandgetWhatsNewFeaturesbefore usingcompareVersions.Edit: Actually, thinking about it,
n.e.x.tisn't appropriate at all, because the feature is not necessarily going to be released in the next version. The catalog entry will be added in the next version, but that's not when the feature is considered released.techanvil commentedon Sep 15, 2026
As mentioned on Slack:
ankitrox commentedon Sep 15, 2026
Thank you @kelvinballoo
I've cerated the follow-up PR for the issue here and also updated the QAB which should no longer throw the error as those properties were referring to
setupCompleteandctafunctions, those are not part of this issue.techanvil commentedon Sep 16, 2026
@kelvinballoo, thanks for catching these, however in light of Mariya's comments on the sheet (here, and here) I've updated the effort for both of these features to 1.
techanvil commentedon Sep 16, 2026
I've merged the following PR. Back to you for another pass, @kelvinballoo.
kelvinballoo commentedon Sep 16, 2026
QA Update ✅
Tested as follows and it's looking good. Moving to approval.
ITEM 2:
The new script does not show the cta error as previously reported.
However, there is a
descriptionerror. As confirmed in slack with Ankit, this can be safely ignored because we haven't implemented successNotice as of now.Details
ITEM 4:
Effort for PSI and dashboard sharing remain at 1.
Details
ITEM 5:
Phrasing has been updated to 'Ad-blocking-recovery' and it's usable in both snippets.
Details
ITEM 6:
Typo has been rectified to
highlightingand the Why-use-list is in the proper sequence.Details