tinymce / tinymce-blazor

Blazor integration
MIT License
45 stars 13 forks source link

Not working in Blazor Webassembly #42

Closed kimermed closed 2 years ago

kimermed commented 2 years ago

I don't see any instructions for using this component with Blazor Webassembly. When trying in a WA project I get this console error:

Unhandled exception rendering component: Could not find 'tinymceBlazorWrapper.init' ('tinymceBlazorWrapper' was undefined).

Do you have instructions for usage in Blazor Webassembly?

exalate-issue-sync[bot] commented 2 years ago

Ref: INT-2843

jscasca commented 2 years ago

@kimermed you just need to add the proper reference to the js library included with the component.

In your wwwroot folder you will find the index.html where you can reference the library. E.G.:

    <script src="_content/TinyMCE.Blazor/tinymce-blazor.js"></script>
    <script src="_framework/blazor.webassembly.js"></script>

Let me know if that helps

kimermed commented 2 years ago

I had those references but in reversed order. Swapping the order fixes it, thanks.