8000
Skip to content

jsep-plugin/new parses new window.Date() incorrectly #278

@zcappp

Description

@zcappp

the latest version (v1.0.4) of @jsep-plugin/new parses new FullCalendar.Calendar() incorrectly, while v1.0.2 is good.
let's take new window.Date() for example:

new@1.0.2 will generate (good):

{
    "type": "NewExpression",
    "arguments": [],
    "callee": {
        "type": "MemberExpression",
        "computed": false,
        "object": {
            "type": "Identifier",
            "name": "window"
        },
        "property": {
            "type": "Identifier",
            "name": "Date"
        }
    }
}

new@1.0.4 will generate (bad):

{
    "type": "CallExpression",
    "arguments": [],
    "callee": {
        "type": "MemberExpression",
        "computed": false,
        "object": {
            "type": "NewExpression",
            "name": "window"
        },
        "property": {
            "type": "Identifier",
            "name": "Date"
        }
    }
}

It might be introduced in issues 243.

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

      0