/
githubmirror
/
wp-calypso
Обзор
Документация
Войти
/
githubmirror
/
wp-calypso
Код
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
trunk
client/reader/liked-stream/controller.jsx
43 строки
998 B
Jarda Snajdr
Rename .js to .jsx (try 2) (#110347)
30 апр 2026, 21:01
Не верифицирован
30 апр 2026, 21:01
d2fc75f
Код
Авторство
О чём код?
import { createElement } from 'react'; import { sectionify } from 'calypso/lib/route'; import { trackPageLoad, trackUpdatesLoaded, trackScrollPage, } from 'calypso/reader/controller-helper'; import LikedPostsStream from 'calypso/reader/liked-stream/main'; const analyticsPageTitle = 'Reader'; const exported = { likes( context, next ) { const basePath = sectionify( context.path ); const fullAnalyticsPageTitle = analyticsPageTitle + ' > My Likes'; const mcKey = 'postlike'; const streamKey = 'likes'; trackPageLoad( basePath, fullAnalyticsPageTitle, mcKey ); context.primary = ( <div> { createElement( LikedPostsStream, { key: 'liked', streamKey, trackScrollPage: trackScrollPage.bind( null, basePath, fullAnalyticsPageTitle, analyticsPageTitle, mcKey ), onUpdatesShown: trackUpdatesLoaded.bind( null, mcKey ), } ) } </div> ); next(); }, }; export default exported; export const { likes } = exported;