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

DatePicker: import Moment from "moment" causes an issue #86

Open
lpetkov opened this issue Mar 12, 2020 · 2 comments
Open

DatePicker: import Moment from "moment" causes an issue #86

lpetkov opened this issue Mar 12, 2020 · 2 comments

Comments

@lpetkov
Copy link

lpetkov commented Mar 12, 2020

Hi,

Importing Moment in the Datapicker component this way:
import Moment from "moment"

Causes the following error when I import the component in Framer:

moment_1.default' is undefined)— index.html:4151

I managed to fix the issue (the component works fine in Storybook and Framer) by importing Moment like so:

import * as Moment from 'moment';

See this discussion that I came across for details: aurelia/skeleton-navigation#606

Thanks,
Lachezar

@ben-schumacher
Copy link
Contributor

Hi @lpetkov, can you submit a PR with your fix. Seems like an acceptable workaround that we can merge into the main branch upon reivew?

@lpetkov
Copy link
Author

lpetkov commented Mar 13, 2020

Done!

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

No branches or pull requests

2 participants