Require Core Assets

Why does this

$v = View::getInstance();
$v->requireAsset(‘core/rating’);

results in this log entry

ResponseAssetGroup::requireAsset required “core/rating” but “core/rating” is not a valid asset group handle

?

With v8 it worked flawless…

Most core assets are now loaded with ‘Features’. The asset mechanism still exists but many core assets either no longer exist or are no longer registered.

thanks for your post. after reading it and the linked articles an I right that core/rating isn’t existing anymore?

but why renders my block when logged in as admin?

AFAIK, the rating code is still there, but it doesn’t exist as an asset you can require. The code is bundled into a feature. When logged in as admin, the feature that includes the rating code is loaded. You will need to work out which feature that is, then modify your block to pull in that feature.

all these breaking changes are a pain in the a**…
and sorry, but the documentation doesn’t help. no code examples or upgrade workflows.