Get 2024 Templates Mega Bundle!14 Bootstrap, Vue & React Templates + 3 Vector Sets
Get for 99$

Metronic (Symfony version) not using Webpack Encore


Hello, I've just bought Metronic for my Symfony 6 project. I'd like to integrate Metronic using Webpack Encore with the `npm run build' command. However, in your Symfony example version, you load the CSS and JS files with a PHP script called 'ThemeHelper'.

I've tried importing only the 'assets' folder and the 'package.json' file to compile with Webpack Encore without success.

Can you explain how to install Metronic using Webpack Encore?

thanks in advance happy


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 happy

Apologies for the delay in getting back to you. Here's a suggestion to integrate Metronic with Webpack Encore in your Symfony project:

Import the Keenthemes assets from /symfony/starterkit/_keenthemes/src/sass/style.scss into /symfony/starterkit/webpack.config.js. You can add it in the section addEntry.

The encore_entry_link_tags and encore_entry_script_tags functions are already added in the /symfony/starterkit/templates/layout/master.html.twig file. These functions are essential for including the compiled CSS and JS files from Webpack Encore.

However, please note that, currently, we do not provide full integration of Keenthemes assets into the default Symfony Webpack Encore configuration. Therefore, you might encounter some challenges in this process. We recommend reaching out to our support team or checking the Keenthemes documentation for any updates or further guidance on integrating Metronic with Symfony using Webpack Encore.

If you need any more assistance or have additional questions, feel free to ask. We're here to help!

Thanks


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  :(