Please see the link https://www.drupal.org/node/2565543
Or in the hook_uninstall() using the following code
OR you can use the following code,
$entityView = \Drupal::entityTypeManager()->getStorage('view')->load('test_view_to_delete'); $entityView->delete();
Or in the hook_uninstall() using the following code
// Deleting the views while uninstalling.
\Drupal::configFactory()->getEditable('views.view.scheduled_content')->delete();
OR you can use the following code,
$entityView = \Drupal::entityTypeManager()->getStorage('view')->load('test_view_to_delete'); $entityView->delete();
Comments
Post a Comment