Skip to content

hdgClass is not defined when library is bundled with rollup #886

@rejhgadellaabsl

Description

@rejhgadellaabsl

What is the current behavior?

When the library is bundled with a tool like rollup like so:

import 'jquery-ui-multiselect-widget';
import 'jquery-ui-multiselect-widget/src/jquery.multiselect.filter';

the output will be wrapped in a "use strict" block. This causes an error when I click an option in the header:

Uncaught ReferenceError: hdgClass is not defined

De hdgClass variable is missing a var (line 1008)

for (hdgClass in i) { /* ... */ }

should be:

for (var hdgClass in i) { /* ... */ }

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo

I've attached the output of the rollop bundle:
lib.jquery-ui-multiselect.min.js.zip

Please tell us about your setup

  • Version: 3.0.1 (via npm)
  • Browser: Chrome
  • Other frameworks in use: Drupal 9

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions