ddubrava/angular-yandex-maps

Add an error if a forRoot method is used not in a root module

Closed this issue ยท 1 comments

๐Ÿš€ Feature Request

โœ๏ธ Description

forRoot must be used only in a root module, check this article - https://angular.io/guide/singleton-services#the-forroot-pattern. So we should add an error if it's imported in children modules.

We can't add an error, it seems it's not possible to determine when forRoot is used outside of a root module. We can only determine when it's used twice but it's not the solution.

Add some documentation changes here - 4e1a082