- 🇦🇺Australia acbramley
This is still relevant, surprisingly the "You have not created any content types yet" message is hardcoded in the node-add-list twig template which is duplicated across 4 themes in core.
IMO this would ideally be in NodeController::addPage but that's probably going to be harder to get in.
Instead we can do something like this in the controller:
if (count($types) > 0 && count($content) === 0 && $user->hasPermission('administer content types')) { // Return a hardcoded message, including cacheable metadata for permissions and the node_type list tag. }