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

We have had the same problem with angular (7/8). #162

Open
dhaneshawate opened this issue Mar 4, 2020 · 3 comments
Open

We have had the same problem with angular (7/8). #162

dhaneshawate opened this issue Mar 4, 2020 · 3 comments

Comments

@dhaneshawate
Copy link

We have had the same problem with angular (7/8).
We ended up with a fork where we added the same core-js polyfills that angular does to avoid the zone.js conflict.

FreeDraw.js:

delete:
import 'core-js';

add:
import 'core-js/es6/symbol';
import 'core-js/es6/object';
import 'core-js/es6/function';
import 'core-js/es6/parse-int';
import 'core-js/es6/parse-float';
import 'core-js/es6/number';
import 'core-js/es6/math';
import 'core-js/es6/string';
import 'core-js/es6/date';
import 'core-js/es6/array';
import 'core-js/es6/regexp';
import 'core-js/es6/map';
import 'core-js/es6/weak-map';
import 'core-js/es6/set';

Originally posted by @AndreasOlausson in #141 (comment)

@dhaneshawate
Copy link
Author

i have added above code but still the issue remains.
please guide according i am trying to do this in angular 9

@AndreasOlausson
Copy link

AndreasOlausson commented Mar 13, 2020

Try to import Freedraw just before you import Zone.

polyfill.ts (something like this):

import "leaflet-freedraw"
/***************************************************************************************************

  • Zone JS is required by Angular itself.
    */
    import 'zone.js/dist/zone'; // Included with Angular CLI.

However, we don't use freedraw any longer, due the lack of "donut-polygon" support so we have written our own "freedraw".

@chriswilley
Copy link

In my case, updating zone.js to 0.10.3 solved this issue.

angular/angular#31724 (comment)

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

3 participants