StaticInjectorError(AppModule)[ctrl_ngx_emoji_mart_CategoryComponent -> EmojiFrequentlyService]:
See original GitHub issueI’m having an issue in my angular app, I’m using v3.0.4
of emoji-mart.
This is a brand new issue I didn’t have previously, but I get the following error when trying to load it:
ERROR NullInjectorError: StaticInjectorError(AppModule)[ctrl_ngx_emoji_mart_CategoryComponent -> EmojiFrequentlyService]:
StaticInjectorError(Platform: core)[ctrl_ngx_emoji_mart_CategoryComponent -> EmojiFrequentlyService]:
NullInjectorError: No provider for EmojiFrequentlyService!
at NullInjector.get (http://localhost:4200/main.ca53750b6edbc91605d8.js:1:674054)
at http://localhost:4200/main.ca53750b6edbc91605d8.js:1:689033
at tryResolveToken (http://localhost:4200/main.ca53750b6edbc91605d8.js:1:689713)
at StaticInjector.get (http://localhost:4200/main.ca53750b6edbc91605d8.js:1:689930)
at http://localhost:4200/main.ca53750b6edbc91605d8.js:1:689033
at tryResolveToken (http://localhost:4200/main.ca53750b6edbc91605d8.js:1:689713)
at StaticInjector.get (http://localhost:4200/main.ca53750b6edbc91605d8.js:1:689930)
at resolveNgModuleDep (http://localhost:4200/main.ca53750b6edbc91605d8.js:1:724014)
at NgModuleRef_.get (http://localhost:4200/main.ca53750b6edbc91605d8.js:1:738204)
at resolveDep (http://localhost:4200/main.ca53750b6edbc91605d8.js:1:745748)
I’m loading it in app.module like so:
import { PickerModule } from "@ctrl/ngx-emoji-mart";
import { EmojiModule } from '@ctrl/ngx-emoji-mart/ngx-emoji'
and in my imports
as
PickerModule,
EmojiModule,
and then my html just looks like this:
<emoji-mart
(emojiClick)="addEmoji($event)" size="16" title="Pick module icon" emoji="point_up"></emoji-mart>
I’m loading it with the MatBottomSheet
from Angular material… Any idea why this might be happening?
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (3 by maintainers)
Top Results From Across the Web
StaticInjectorError(AppModule)[UserformService -> HttpClient ...
Simply i have import in appmodule.ts import { HttpClientModule } from '@angular/common/http'; imports: [ BrowserModule, FormsModule, ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
the last version that works with angular v8 is 1.0.6 https://github.com/TypeCtrl/ngx-emoji-mart#dependencies
npm should warn you when you install them, but you can sometimes also find out by looking at peerDependencies