Skip to main content
drupalreleases

Use direct release data with your AI assistant.

Learn more

Log Context

No security coverage No further development

Part of the LOG ecosystem · 11 projects

This module helps developers diagnose JavaScript errors that occur when using AJAX. It logs context information to the console whenever Drupal behaviors are attached, making it easier to identify issues like duplicate event handlers that can arise from improper AJAX implementation.

This is a Dev module

This module is intended to make local development easier. It is not intended to be installed on production sites.

What does it do?

  1. This module logs the "context" js variable to the console any time that Drupal.attachBehaviors is called.
  2. It provides a test function you can call from the console to see if your site if "ajax proof."

Why is this helpful?

These logs can help developers when AJAX is used on the page.

When AJAX is used and you haven't leveraged context or jquery.once in your scripts it is likely that front-end bugs will be introduced. For example, click handlers may be applied more than once leading to unwanted "repeating" or sometimes "destructive interference." These bugs may be easier to diagnose if this module is installed.

There are other times (like with modals) that you might think something is in context, but it really isn't. This module can help you figure that out too.

In short, ajax bugs are easier to fix when you have this module installed. See the Drupal JS API reference for more information on context.

Ask your assistant about Log Context

Check compatibility with your Drupal and PHP version, maintenance and security coverage, from current release data. How it works

Depends on

Dependencies of the latest stable release

No dependencies recorded for this project.

Required by

Tracked projects that depend on this one

No tracked projects depend on this one yet.

Activity

Tracked releases
1
Tracked since
Apr 2024
Latest release
2 years ago
Releases (12 mo)
0
Maintenance
Dormant

Releases

Version Type Core PHP Release date
8.x-1.0-alpha4 Pre-release 9–11 Apr 30, 2024