Skip to content

Incompatibility with TypeScript (edge case) #76

Description

@pfumagalli

I have a very simple TypeScript file:

export { default as bar } from './bar'

When transpiled with tsc (4.8) and esModuleInterop set to true the transpiled code will somehow look like this:

"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.bar = void 0;
var bar_1 = require("./bar");
Object.defineProperty(exports, "bar", { enumerable: true, get: function () { return __importDefault(bar_1).default; } });

In this case, the lexer seems to be ignoring the bar export.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions