What's the best way to integrate to a new Rails project?

hi, I have buy metronic themes and be ready to use them in my ruby on rails project, however, metronic theme is huge for me, so can you tell me: How I build my prototype? How I reduce the unnecessary js,css? How I make my layout? ... I need your best suggestion, thank all.

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 (3)

Hi Changwu

You can use the HTML version to integrate into your existing project because you will use the HTML template.

You can go to the index.html template and check the CSS and js included in the template head and foot. Once you fully understand what are CSS and js files to include in each page of your application the rest will be quite easy.

2. You can use the layout builder to prepare your HTML template. For example, if you are using the demo1 you can go to the online preview of the demo:

https://preview.keenthemes.com/metronic8/demo1/layout-builder.html

The layout builder helps you to configure the layout with available options and preview it in real-time. Once you decide what configuration you like to use you can download the HTML code of your preferred configuration. To do so go to the bottom of the page and find the "Export" button and you will get a package containing the HTML template with the partials(header, aside, footer, etc) that can be used for your server-side integration. The export package provides you with only the HTML code with structured includable partials that are perfect for server-side integration. The assets can be included in your local download version.

3. Once you integrated the master layout and all the menus and navigation you can proceed with your inner pages by referring to the original theme demos.

4. Also as the main reference to the available features, you can refer to the demo pages' source code for each feature.

If you need any further help, please let us know.

Thanks

Thanks. Hard-copy need more patience. I found the gulp‘s script can product js and css assets, if I use gulp build my prototype, then copy js&css assets into rails, is this way right?

Hi Changwu

The gulp builds the assets. You can find the required assets from the HTML version.

/html/demo1/dist/assets/plugins/global/plugins.bundle.js
/html/demo1/dist/assets/js/scripts.bundle.js

/html/demo1/dist/assets/plugins/global/plugins.bundle.css
/html/demo1/dist/assets/css/style.bundle.css

You can also remove unused 3rd party plugins for gulp build from here;
/html/tools/gulp.config.js

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