It should compile.
I get the following error:
ReferenceError: babelHelpers is not defined
(anonymous function)
node_modules/react-popper/lib/Manager.js:5
2 | import PropTypes from 'prop-types';
3 |
4 | var Manager = function (_Component) {
> 5 | babelHelpers.inherits(Manager, _Component);
6 |
7 | function Manager() {
8 | var _ref;
Installing 0.10.1 manually fixes the problem. I can provide more info if necessary although given that the new version was only just released, I was hoping it would be an obvious fix.
@virgofx since you worked on the 0.10.2 changes, may you have a look?
@FezVrasta external-helpers should be added only for rollup build. For babeled files it shouldn't not be added.
Here it can be moved to rollup config
https://github.com/FezVrasta/react-popper/blob/v0.x/.babelrc#L8
Investigating
0.10.3 fixes it
@TrySound @davidxmoody Can you check 0.10.3 and confirm fixed?
The babelhelpers are not referenced in the file anymore so hopefully yes.
https://unpkg.com/[email protected]/lib/Manager.js
But I just noticed that the package.json points to an invalid main path, is it still related to your PR maybe?
I actually didn't change the package.json file (not too familiar with the main or umd:main references). ... but the locations should be updated. I'm sure I could submit a new PR to update those. It seems like they should be updated (good catch).
Should the main point to the lib/react-popper.js or the CJS file? and umd:main to the new dist/umd/react-popper.min.js file?
also consider jsdelivr and unpkg properties in the package.json (and maybe even cdn). They are properties which help the CDNs determine which file to server.
See:
https://github.com/unpkg/unpkg/issues/63
https://github.com/jsdelivr/jsdelivr#publishing-packages
0.10.3 introduces another problem. package.json references dist/react-popper.js but this file doesn't exist.
0.10.4 should be fine hopefully
Most helpful comment
0.10.4 should be fine hopefully