-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Fix rollup error. #1556
Fix rollup error. #1556
Conversation
Rollup cannot process `import * as moment from 'moment'`, instead `import moment from 'moment'` should work. See rollup/rollup#670
Thanks, I will try this with webpack and system.js and merge |
I realized that I actually did break typescript compilation. Setting |
There are were an issue with such imports earlier, when ts typings was in issue |
Current coverage is 84.96% (diff: 100%)
@@ development #1556 diff @@
=============================================
Files 82 82
Lines 2301 2301
Methods 20 20
Messages 0 0
Branches 298 298
=============================================
Hits 1955 1955
Misses 246 246
Partials 100 100
|
with I am getting
from |
Yeah. See my previous comment. Setting "allowSyntheticDefaultImports" to true fixes it. |
Btw, if anyone needs this fix urgently, I temporarily published version 1.3.0 with this fix included at https://github.com/jimmytheneutrino/ng2-bootstrap/releases/tag/v1.3.0-fix.2 . This should work with npm/yarn like this: "ng2-bootstrap": "https://github.com/jimmytheneutrino/ng2-bootstrap/releases/download/v1.3.0-fix.2/dist.tgz" |
In the 1.7.1 npm, |
Merge conflict, actually |
In our project we ended up creating a utility module a la
and using it like This should be ok for all environments. |
I couldn't use ng2-bootstrap's datepicker as is with rollupjs because rollup cannot process
import * as moment from 'moment'
, insteadimport moment from 'moment'
should work.See rollup/rollup#670