Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modules that import @elastic/eui are failing #43

Closed
nickythorne opened this issue Sep 21, 2021 · 0 comments · Fixed by #50
Closed

Modules that import @elastic/eui are failing #43

nickythorne opened this issue Sep 21, 2021 · 0 comments · Fixed by #50

Comments

@nickythorne
Copy link

We use bit.dev to manage common components. These common components have @elastic/eui as a dependency and are built and packaged by webpack. Example build module here:

"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.TestComponent = void 0;
const react_1 = __importDefault(require("react"));
const eui_1 = require("@elastic/eui");
function TestComponent({ text }) {
    return (react_1.default.createElement("div", null,
        react_1.default.createElement("p", null, "Test Component"),
        react_1.default.createElement(eui_1.EuiText, null, `EUI: ${text}`)));
}
exports.TestComponent = TestComponent;
//# sourceMappingURL=test-component.js.map

The package has worked great for us up until this point, but unfortunately the webpack config to provide stubs for react-ace doesn't work when the elastic dependency is requested in an imported module.

Any ideas how we can get this to work?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant