Get 2024 Templates Mega Bundle!$1000 worth of 19 Bootstrap HTML, Vue & React Templates + 3 Vector Sets for just $99
Get for 99$

Add theme into existing Wasm Hosted project


Hi. I have been trying to use Metronic Theme in an existing WASM Hosted project, but when i run the app, it throws an error, it can't find the file: themesettings.json.

When i run your Blazor demo included in the download package, it runs without problems, but once i take the same directories and try to run in Client Project, it fails. the WASM solution has 3 projects, Server, Client and Share. Maybe there are something diferent when i run your demo is a Serverside app, but it does not work in Clientside mode.

I'm wondering if you can help me with it?

-------------------------------
Here is the error:
System.IO.FileNotFoundException: The configuration file '_keenthemes/config/themesettings.json' was not found and is not optional. The expected physical path was '/_keenthemes/config/themesettings.json'

-------------------------------
Here is the line in my Client.Program file:

string jsonDir = Path.Combine(AppContext.BaseDirectory, "_keenthemes/config/themesettings.json");
IConfiguration themeConfiguration = new ConfigurationBuilder()
.AddJsonFile(jsonDir)
.Build();


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(

Replies (1)


Hi,

Thank you for reaching out to us.

Unfortunately, we have not yet attempted to convert our Blazor Server Side theme to Blazor WASM.

Based on the error message, it appears that the application is referencing a non-existent file. In the default package, we load themesettings.json from the _keenthemes/config folder. Please ensure that you have included this folder in your project and that themesettings.json exists in _keenthemes/config.

Regards,
Lauris Stepanovs,
Keenthemes Support Team


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(
Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(