0

I have question about using JS files from sub component libraries. I have a Blazor WASM site and I have created a custom component library for this. In my custom component library I am using the BlazorInputFile library as well. To get this work in the main WASM index.htlm I have to add <script src="_content/BlazorInputFile/inputfile.js"></script>. which is fine but not as elegant as I would like. Is there way to say <scriptsrc="_content/myCustomLibrary/BlazorInputFile/inputfile.js"></script>? I have also tried <scriptsrc="_content/myCustomLibrary.BlazorInputFile/scripts/inputfile.js"></script>

What are the best approaches for writing comment libraries that themselves rely on other third part component libraries? IS there a better way than needing to manually reference the sub component static recourse one-by-one.

Andrew
  • 51
  • 2
  • if you could include a javascript file in another javascript file you can achive what you want. so read this : https://stackoverflow.com/questions/950087/how-do-i-include-a-javascript-file-in-another-javascript-file – nAviD Dec 03 '20 at 18:40

0 Answers0