Newest learning path "Liquid Storefronts for Theme Developers" needs some QA

I am trying to develop the knowledge necessary to pass the assessment for this badge. I know this message is a bit long, but hopefully it is easy to follow. I hope someone from Shopify will read this message and follow up with those in charge of developing the curriculum in the Shopify Academy, because I am fairly certain that this new course has both flaws and lacks adequate directions to accomplish the task associated with the labs. While the information on each topic seems scant and wanting,perhaps it may be made up for by a focused reading of the docs. However, the Labs in Theme architecture with Liquid for Developers are confusing, if not definitively incorrect. There are gaps in the steps and the logic needed to complete the task seems to be disjointed.

Lab 1

states: “The collection title is displayed accordingly and the link leads to the collection URL.” Using the code below it is assumed that the each collection’s title will be used as a link to the collection’s url

    <li>
       <h5>Collection card</h5>
       <div class="card">
         {% for collection in collections %}
         <div
           class="media"
           style="--width: {{ collection.image.width | default: 100 }}; --height: {{ collection.image.width | default: 100 }};"
         >
           {{ 'collection-1' | placeholder_svg_tag }}
         </div>
         <h2>
           <a href="{{ collection.url }}">{{ collection.title }}</a>
         </h2>
       {% endfor %}
       </div>
     </li>

This creates one large card with every collection pointed to whatever collection is positioned last in the the list of collections.

Below is my code enabling each collection to use its associated url in the href link

{% for collection in collections  %}
       - ##### Collection card
         
         
          

              {{ 'collection-1' | placeholder_svg_tag }}
          

            ## 
              {{ collection.title }}
          
        

      

       {% endfor %}

Lab Part 2: Analyze Accelerator theme code

References a main-collection-grid.json in the sections directory, which I think is actually suppose to be main-collection-grid.liquid. At least from what I can recall from my studies, the footer-group and header-group are the only 2 files in the sections directory that can be .json files. Moreover, there is no file called main-collection-grid.json.

Question Posed: How does the when ‘text’ block render the vendor information?

Answer: The when ‘text’ block uses {{ block.settings.text }} to render the vendor information. In your product.json, the vendor is set as {{ product.vendor }} in the text block’s settings. This outputs the vendor’s name in uppercase, as specified by the text_style.

I have been unable to see text_style have any effect on the name of the vendor.

The following code

   "blocks": {
        "vendor": {
          "type": "text",
          "settings": {
            "text": "{{ product.vendor }}",
            "text_style": "uppercase"
          }
        }

does not render an “uppercase” when applied to

    <div id="Product-Info-{{ section.id }}">
      {%- assign product_form_id = 'Product-Form-' | append: section.id -%}
      {%- for block in section.blocks -%}
        {%- case block.type -%}
          {%- when '@app' -%}
            {% render block %}
          {%- when 'text' -%}
            <p {{ block.shopify_attributes }}> 
// this text  is associated with vendor and should receive the upper case style
              {{ block.settings.text  }}
            </p>

Since I believe the goal of this lab was to have this text style applied from the theme editor ( or based upon changes performed in the product.json) how should this styling be accomplished?

Also if anyone can point out where in the documentation “text_style” is used, that would be extremely helpful. Thus far, I have not found a reference to "text_style " explained as an attribute for “settings”.

In the Dawn theme I have seen it is applied as a class

          <div class="banner__text rte {{ block.settings.text_style }}" {{ block.shopify_attributes }}>
              <p>{{ block.settings.text }}</p>
            </div>

( which I tried to do in this theme as well without success). If this is how we are expected to achieve this outcome, then there needs to be better guidance. I have used css “text-transform: uppercase” in a class but I do not understand how this happens when it is being inject into a class using “text_style: uppercase”.

Lab Part 3
This is the real reason I have spent some much of day writing this post. I was able to create the metaobject and 2 metafields for the labs in the Shopify Development Fundamentals but how to use the work from that lab to accomplish the work that needs to be done is this lab is beyond what I can deduce from the instructions provided.

After applying the model_info to the product.json structure per the instructions.

{
  "sections": {
    "main": {
      "type": "main-product",
      "blocks": {
        ...
        "model_info": {
          "type": "model_info",
          "settings": {}
        }
      },
      "block_order": [
        "vendor",
        "title",
        "caption",
        "price",
        "variant_picker",
        "quantity_selector",
        "buy_buttons",
        "description",
        "model_info"
      ],
      "settings": {}
    },
  },

I have been unable to get the model info to appear as a block or section of the theme editor, and I am not even sure it should be done with the theme editor, as it clearly states in the lab " In this task, we’re going to recreate this PDP element using Liquid instead."

It would great if someone from shopify can expound on my questions and concerns.

Hi there @Streeter ! I am the one behind these activities, and thank you so much for surfacing these, let me take a look and see how I can implement the fixes, and also answer some questions you have here.

Hi @whatupfoo
Thank you, for creating the labs. I realize developing curriculum can be tough, especially when the knowledge you need to put forth includes tools that require so much nuance instrumentation. I also realize that both the teacher and the students do the teaching. Or, that we as the students need to dig and figure some of this out for ourselves, but for what it’s worth here are a couple of areas that I think would be a tremendous assist to helping students grasp the concept put forth in the labs.

  • I thought that the objective of this Lab 3 was to utilize liquid to implement what we had done with metaobjects and metafields in the Shopify Development Fundamentals lab in which we were relying on proper configuration of the shopify admin and theme editor.
  • Perhaps provide us with view of the expected outcome, either in code and screen snapshots or both of what we should end up with once we have followed the steps you have laid out.
  • I think providing even more granular and more obvious (non-opaque) steps toward how we achieve the final lab will helps us gain the insights of how a liquid coding implementation is related to the actions we can achieve when using the the Theme Editor.
  • The Theme blocks labs did not work for me but, I was able to follow this youtube video Shopify Flex Sections (Theme Blocks & Style Settings Preview) and create blocks and section for theme blocks that worked in the Dawn theme version of the Shopify store that I set up in your Shopify Development Fundamentals labs.

Lastly, a more general observation about these courses so far, I think there needs to be more emphasis on the structure of these liquid files and how they function overall.

  • How variable scope from template, to section, to theme blocks and snippets is applied ( like the {{ closest.}} concept to reference a variable)
  • Perhaps more the “gotcha” nuances of using liquid. ( ex. this for loop error in the collection.url is similar to a “gotcha” error in javascript that occurs due to a facet of variable hoisting)
  • How section.settings and block.settings are implemented and how to arrange them with code such that those who only use the theme editor can develop the style of their storefronts.

Once again, thank you for responding to my concerns.
P.S. your fellow shopify staff member @SarahF_Shopify implied a new version the “Liquid Storefronts for Theme Developers” was released yesterday, but nothing has changed from what I can see. I wonder if because I have completed 2 of the 3 lessons in the learning path, it is preventing me from view the newly revised material. If this is the case, is there anyway you can unset my completions of this learning path as I would like to have perview the latest teaching before taking the assessment.

Ah okay, I went through all your concerns and super appreciate your effort in writing this up, as well as your effort in digging deep in the activities!

For Lab 1:

I agree, I failed to check that the if statement was working well, I will implement this fix!

For Lab 2:
This was an interesting one. I did some digging and it was a line of Liquid code that was left behind when the team attempted to provide a stripped down version of Dawn. You are right in that you can use CSS class for and this line can be removed from templates/product.json

"text_style": "uppercase"

I will also implement the changes ASAP, so sorry for the confusion there!

For Lab 3:

I have been unable to get the model info to appear as a block or section of the theme editor, and I am not even sure it should be done with the theme editor, as it clearly states in the lab " In this task, we’re going to recreate this PDP element using Liquid instead."

Ah I see what you’re saying here, this was related to the Development Fundamentals course as you’ve mentioned, and I was sort of using that as a continuation for this activity. I see now that in the learning path, I used a screenshot with “collapsible row” block type which does not exist in the Accelerator theme.

For the fix, I will say that you can add any block to the theme editor, in this screenshot, I’m using a “text” block:

And then select the “Connect dynamic source” database icon button on the top right corner:

And select the metafields & metaobjects from there:

When we head back to the code editor, in the templates/product.json, we now have the Liquid syntax of the metafields & metaobjects that we can learn from:

Because learning how to write syntax to access metafields and metaobjects is tricky (especially when it comes to referencing metaobjects in a metafield), we figured that teaching this “roundabout” way could help developers arrive at solutions faster.

Again, I really appreciate you highlighting all the errors! Sorry for all the inconvenience here, I will make those changes as soon as we can :blush:

Yeah, indeed I am learning too while trying to resolve these errors! That’s the nature of the work :grinning_face: Even though a developer’s work is all code and logic, it’s challenging to create learning paths for a job that really can be more of an art sometimes.

I thought that the objective of this Lab 3 was to utilize liquid to implement what we had done with metaobjects and metafields in the Shopify Development Fundamentals lab in which we were relying on proper configuration of the shopify admin and theme editor.

I see! I created this activity in collaboration with the product manager of metafields & metaobjects, who felt like it was important to show Developers quick solutions to the problem. But I take your point, I implemented a fix that makes the goal of the task more explicit and clearer to the learners.

Perhaps provide us with view of the expected outcome, either in code and screen snapshots or both of what we should end up with once we have followed the steps you have laid out.

While resolving these errors, I also realized that many of my screenshots did not make it to the final output, I have flagged them for the team to fix. I am also hoping that I could attach solution videos for the second phase just like in Developement Fundamentals so it takes the guesswork out.

The Theme blocks labs did not work for me

Hmm, I was able to complete this. I will log this as something we could tackle as the next version of the course to add more content, and thanks for sharing the video too! This seems way better than what I was able to do.

Also thanks for all the other feedback, definitely will be something we can improve on! I talked to @SarahF_Shopify and she was referring to this exact Liquid path that you’re on, so no new change – until we launch these fixes!

@whatupfoo
Thank you and I hope you have a happy holiday :smiling_face_with_sunglasses: