code: public function onBlockEditing(BlockEditingEvent $event)
      {
          $encodedBlock = $event->getFileContent();
          $htmlBlock = $this->pageProductionRenderer->renderBlock($encodedBlock);
  
          $this->permalinkManager
              ->add($event->getFilePath(), $htmlBlock)
              ->save();
      }
docs: Adds the edited block to PermalinkManager object
  
  @param \RedKiteCms\EventSystem\Event\Block\BlockEditingEvent $event