0

I have tried several methods to bring an html template to Magento2.

One was to simply load style sheets from the template I was working on. The styles were mixed with the standard template, and the page was defaced. It was useless, but that was expected!

In another attempt, I tried to use reset css techniques, with the hope of "zeroing" the style, and making my custom.css serve as a new style. It was useless.

A third attempt was to search the documentation, to try to configure an XML page with full width, so theoretically I could fill it with html from my template, and have full width features.

Documentation references were not the same as the platform screen, even using magento 2.3.5. Did not work!

One last attempt was to try to find some standard file (within the theme I created), of the type "style.css". It was a cloned Luma theme.

I didn't try to change the Vendor folder! However, pretty much all of the standard style sheets were .less, which I don't know how to work with, let alone knowing what the theme's pattern would be.

I would like to know how is the best way to 100% clone an html template for a Magento2 theme that I create!

1

I do this for 404 pages in my extension

https://github.com/DominicWatts/Lightweight404

So completely strip back page including removing most of header and footer

Maybe you can look at layout XML and figure out how to implement for particular CMS page via layout override or custom page layout in backend.

1
  • That is exactly what I tried on page page_not_found.xml. Remove de CSS default And it works! – Paulo Sérgio Duff Aug 16 '20 at 20:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.