class BigPipeBypassJsHooks

Hook implementations for big_pipe_bypass_js.

Hierarchy

Expanded class hierarchy of BigPipeBypassJsHooks

File

core/modules/big_pipe/tests/modules/big_pipe_bypass_js/src/Hook/BigPipeBypassJsHooks.php, line 12

Namespace

Drupal\big_pipe_bypass_js\Hook
View source
class BigPipeBypassJsHooks {
    
    /**
     * Implements hook_library_info_alter().
     *
     * Disables Big Pipe JavaScript by removing the js file from the library.
     */
    public function libraryInfoAlter(&$libraries, $extension) {
        if ($extension === 'big_pipe') {
            unset($libraries['big_pipe']['js']);
        }
    }

}

Members

Title Sort descending Modifiers Object type Summary
BigPipeBypassJsHooks::libraryInfoAlter public function Implements hook_library_info_alter().

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.