Explore the categorized logging system with runtime controls
🌐 client — runs in the browser (element JS API) 🖥️ server — LiveView round-trip
Global registry (no wrapper attribute): the bundled multiselect.js auto-installs
window.components['web-multiselect'] via core's registerComponent()
Every KeenMate component publishes one entry via core's
registerComponent(). Below is a live view of
window.components['web-multiselect'], refreshed automatically
as instances connect and disconnect.
The .logging object is the flattened logger bundle:
reg().logging.setCategoryLevel('DATA', 'debug')
The .logging object is the flattened logger bundle. These
buttons call it directly (e.g.
window.components['web-multiselect'].logging.setCategoryLevel('DATA','debug')).
The active category level is reflected in the registry panel above. Interact
with the pickers to produce logs.
Global registry (no wrapper attribute): reg().getInstances()
returns the connected <web-multiselect> elements
getInstances() returns the connected elements of this tag —
maintained automatically (added on connect, removed on disconnect). Add and
remove pickers below and watch the count in the registry panel change; then
fan a call out across every live instance.
Here's how to control logging programmatically:
// Import logging utilities
import { enableLogging, setLogLevel, setCategoryLevel, disableLogging }
from '@keenmate/web-multiselect';
// Enable all logging at debug level
enableLogging();
// Set specific log level for all categories
setLogLevel('info'); // 'trace' | 'debug' | 'info' | 'warn' | 'error' | 'silent'
// Enable/disable specific categories
disableLogging(); // First disable all
setCategoryLevel('UI', 'debug'); // Debug only UI operations
setCategoryLevel('DATA', 'info'); // Info level for data operations
setCategoryLevel('INTERACTION', 'silent'); // Disable interaction logs
// Disable all logging (default for production)
disableLogging();
JS import (no attribute): call enableLogging() · disableLogging() · setLogLevel("info") from @keenmate/web-multiselect
Enable and disable logging at runtime. Watch the console as you interact with the multiselect.
JS import (no attribute): setCategoryLevel("DATA", "debug") per category · close_on_select={false} keeps the panel open while you watch logs
Enable logging for specific categories only. This example has async search enabled - type to see DATA logs. Try enabling different categories to see different types of logs.
min_search_length={3} gates the search · JS callback (no attribute): el.beforeSearchCallback strips accents before the query
Show popular items initially, then switch to web service search. Demonstrates beforeSearchCallback for accent removal.
(pick an option anywhere on this page)