I got the following error when trying to install the lib
trex@cave:/media/trex/safe1/Development/kibanaPlugin$ npm install @elastic/eui --save
npm ERR! code EUNSUPPORTEDPROTOCOL
npm ERR! Unsupported URL Type "npm:": npm:@elastic/[email protected]
npm ERR! A complete log of this run can be found in:
npm ERR! /home/trex/.npm/_logs/2018-10-11T12_35_29_763Z-debug.log
In my plugin I use lodash v4.17.10.
The lib is installed well if I manually add "@elastic/eui": "4.0.0" to packages.json and do npm install
The EUI library does not support being installed via npm - you must use yarn.
@chandlerprall but there is this instruction in the readme https://github.com/elastic/eui#installation
npm install @elastic/eui
I'll update that doc, thanks!
I am using EUI for a plugin that is compatible with Kibana 6.1.x. Now I assume EUI (from 4.3.0 upwards, from my tests) can no longer be used to write plugins for Kibana versions lower than 6.2 (I recall that's when yarn was introduced)?
You're correct, yarn was introduced in Kibana 6.2 (https://github.com/elastic/kibana/pull/15485).
If your plugin authoring process requires EUI to be installed/managed by Kibana, you would need to stick to a pre-4.3.0 EUI. However, if you're able to build your plugin code outside of Kibana you should be able to use any version of EUI.
Just for the sake of discussion, I'm curious about the decision to only support installation via yarn and not npm. Is that decision documented somewhere? I'd also be curious if we're thinking about adding npm support again at some point and it's just not a top priority.
Background: I'm playing with using EUI to manage layout and default styles for a non-Kibana UI that Infra is working on and stumbled around for a little while trying to get it installed before realizing the docs said it was Yarn-only.
I'd love to help work on adding npm support, unless I'm the only person who thinks the effort would be worth it. 馃檪
We're using yarn's ability to alias packages to use Elastic/Kibana's version of [email protected], which contains a security fix. This is meant as temporary (though low priority) until we either migrate to lodash 4 or off lodash entirely ( #360 )
Most helpful comment
We're using yarn's ability to alias packages to use Elastic/Kibana's version of [email protected], which contains a security fix. This is meant as temporary (though low priority) until we either migrate to lodash 4 or off lodash entirely ( #360 )