Closed drma-tech closed 2 years ago
Hi @drma-dev
Update wwwroot/index.html
and add these two lines:
<link href="_content/GEmojiSharp.Blazor/style.css" rel="stylesheet" />
<script src="_content/GEmojiSharp.Blazor/script.js"></script>
It is briefly mentioned in the README, but I should clarify the documentation.
You can take a look at line 12 and line 47 of a sample index.html
.
I did it and that's exactly why this error is happening (he tries to look for something that doesn't exist). You must have the reference in program.cs
Right. I think you need to import the GEmojiSharp.Blazor
namespace in the _Imports.razor
file.
Check out the sample file at line 11.
References in _import.razor only allow the use of components within razor pages.
To recognize the js and css files (of any component) you need to create these references within program.cs (or startup.cs, depending on the type of project).
It would have to have a code something like this:
Services.AddGEmoji();
This tells the project that there are static files that need to be read at startup.
I don't know how to reproduce this.
Are you able to run the sample app?
I didn't see anything in the documentation about something to register the dll in program.cs so that these files can be recognized