• Resolved iantresman

    (@iantresman)


    What are Styles, Scripts and Layouts for? The WP Tangible menu has four options:

    1. Templates (described in the documentation)
    2. Styles
    3. Scripts
    4. Layouts

    But the documentation overview does not mention Styles, Scripts and Layouts. Interestingly, when I add a new Template, there are submenus for Styles and Scripts (are these related to the main menu items, or are they local to the defined template. And then there are assets which are beautifully documented.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plugin Author Tangible

    (@tangibleinc)

    Hi there,

    Templates: Allow you to pull in a self-contained bundle of markup/css/scripts/assets into your content or theme or page builder as needed. Can also be included in other templates or loaded into layouts, etc. Can be useful if several of your layouts have shared elements.

    Styles: Allows you to load a SASS stylesheet according to conditional logic rules. This could be useful if instead of having your CSS bundled with your templates/layouts, you prefer to style many templates/layouts using a single stylesheet. It can also be a way to separate concerns if you’re building a library of templates/layouts to use between sites. If you keep the markup versatile enough for all your projects, you can just vary a single unified stylesheet on each client project while keeping all the same templates/layouts between them.

    Scripts: Allows you to load a Javascript script according to conditional logic rules. Could be useful if several templates/layouts rely on the same JS. You can also use it for things like adding a Google Analytics tracking code or conditionally loading up Google Maps JS exclusively on the page you want to render a map, etc.

    Layouts: Essentially an L&L template applied to a theme template. Much like Gutenberg’s FSE, Elementor’s Theme Builder or Beaver Builder’s Themer, but for applying L&L to theme templates at parts (where compatible). With these you can essentially replace your entire theme with L&L using our location rules.

    • This reply was modified 2 years, 9 months ago by Tangible. Reason: bolding sections for legibility
    Thread Starter iantresman

    (@iantresman)

    Much clearer, thank you.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Styles, Scripts and Layouts?’ is closed to new replies.