Change record status: 
Introduced in branch: 
8.x
Description: 

In order to simplify the way to integrate a module with views , hook_views_api() has been removed. This means that you can no longer place the .views.inc file in a subdirectory. It now must be in a .views.inc file in the root of your module.

Drupal 7

foo/foo.module

function example_views_api() {
  return array(
    'api' => 3.0,
  );
}

foo/views/foo.views.inc

function foo_views_data() {
  ...
}

Drupal 8

foo/foo.views.inc

function foo_views_data() {
  ...
}
Impacts: 
Module developers
Updates Done (doc team, etc.)
Online documentation: 
Not done
Theming guide: 
Not done
Module developer documentation: 
Not done
Examples project: 
Not done
Coder Review: 
Not done
Coder Upgrade: 
Not done
Other: 
Other updates done

Comments

DanChadwick’s picture

Hooks which must be run during each view execution, such as hook_views_query_alter() must placed in foo.views_execution.inc, rather than foo.views.inc.