Skip to content

Native classes controllers not working #228

Description

@rumkin

There is an issue with native class controllers in Chrome. Controller like this:

alight.ctrl.test = class {
    constructor() {;
        this.value = 1;
    }
};

and html like this:

<div al-ctrl="test"></div>

could not be initialised due to new error:

Error in controller: test Class constructor  cannot be invoked without 'new' Object {name: "test", env: Object, scope: d, element: div} TypeError: Class constructor  cannot be invoked without 'new'

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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