Skip to content

EVENT: Optimizing the handler function registration #8

@pauleveritt

Description

@pauleveritt

There's a lot of potential YAGNI below. If needed at all, unlikely to be needed any time soon.

When I was doing empty_button with mousemove event I thought: I bet my CPU is getting toasty. Lots of likely-expensive calls across the proxy. It made me think: we could put a wrapper on the JS side that did a little mediating before calling the registered proxy.

Debouncing

The decorator could have an optional value to set some debouncing policy.

Logging

When trying to figure out what's going on with events, this wrapper would provide a central place to collect info. Perhaps with a py-config knob.

Expression

I'm kinda proud of this one. Write a truth-y arrow function that gets run to determine whether to call the proxy.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions