Skip to content

Refactor recalcAttrs #1578

Closed
Closed
@rreusser

Description

@rreusser

Carpet is going to add a huge number of attrs to recalcAttrs. (up to 287 total or so!?) The array of attributes is recalculated on every plot and it looks them up with indexOf. It should place them in a hash (e.g. {mode: true, visible: true, ...}) and should be defined in a plot-api-global context since it never changes.

@alexcjohnson notes that a larger refactoring is desired, but this might be a start since, at least once carpet is merged, it shouldn't take more than five minutes and may very well be at the point of having a non-negligible impact on performance.

cc @etpinard

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