Views hook gets ignored after 1 execution I registered this hook in my module:

function MYMODULE_views_pre_render(\Drupal\views\ViewExecutable $view) {
        die('hello world');
}


I cleared the caches, and ran a view.

Output is "hello world" as expected.

I refreshed the view, and my pre_render plugin is completely ignored (view is shown normally).

What's happening?
Solution is to put the code in a file called MYMODULE.views_execution.inc.
I was using MYMODULE.views.inc