Notes
Notes by Jason Bowman on Shopify, data, hardware and the tools he builds. Most are published on the Freakdesign blog.
- Put a theme release in Shopify Analytics When I look back at a Shopify traffic report, I want to know what changed around the time the numbers moved. If I shipped a different navigation or changed a product page, I'd rather see the date on the chart than dig…
- Energy Clock: a Powerwall monitor I can read at a glance I wanted to see how much charge was left in the Powerwall and what the solar was doing without opening an app. I had a few ESP32 displays around the house, and the round one ended up becoming a clock.
- Show returning customers what they’ve bought before in Shopify If I’m looking at a refill or a replacement part, there’s a good chance I’m trying to buy the same thing again. I'm also prone to forgetting I bought a thing during some early AM coding session break so end up with…
- I got distracted for a second By "a second" I mean a few years. I do much the same thing on LinkedIn. I remember it exists, post something, then get distracted again. I also need to get back to some forum posting but one thing at a time Jason...
- NBN Skymesh (Sky Muster) vs Starlink and the joys of working remote Join me on the adventure of testing available internet services like Starlink and Skymesh (Sky Muster) in an Australian rural location, all while trying to work remotely at a global technology company. Being a nerd…
- Could multiple 404 pages be better than one? If you've read my posts you'll know that things talked about here are a mix of crazy and silly. Let's hack around with Shopify 404 page so you make use of different versions and show different content.
- ShopifyFD and the current case of the broken tool. Update. ShopifyFD was a browser tool I built for an earlier version of Shopify Admin. It no longer works in the current Admin. There’s no new version planned. If there’s a gap worth solving in Shopify’s built-in…
- How to get the Shopify cart.token property in Liquid If you check the Shopify docs for the cart object you'll note that the token is missing. Referencing the value using {{ cart.token }} won't work so here's a method that can be used instead.
- Australian GST will be applied to your next Shopify bill In case the image doesn't load it reads:
- Store the code used in Shopify shareable discount urls Shopify recently dropped a feature that allows discount codes to be shared in a url - aptly called Shareable Discount Links. I had a few people ping me on how they can access the actual code used one the storefront so…
- Show the Shopify gift card variant image on the gift_card.liquid template Shopify Gift Card images are something you can customise but it's not as simple to show the actual variant image on the page the customer sees. Let's look at some code to let you show the variant image in the Gift…
- Add specific blog posts to a Shopify page using only Liquid (no JS) If you'd been paying attention to the Liquid documentation changes you would have seen something new appear to the Liquid Objects page (under articles). It highlights how to directly reference an article in Liquid -…
- Show multiple shopify product reviews on one page The Shopify Product Review app is a great (and free) way to get that social proof and trust built into your products. One thing it doesn't do well is to collate the reviews onto a single page - let's explore some…
- Disable ?sort_by=best-selling on Shopify collections Shopify allows you to dynamically adjust the order of a collection using the sort_by querystring in the url. Let's explore some simple code that makes it harder for a customer to use that sorting querystring to see…
- Hacking the Shopify sort_by querystring to do fun things The fun thing about the undocumented sort_by property on collections is that you can pass whatever string to it that you like, and then be able to use it in Liquid. It's a pretty gross hack, but it might come in handy…
- Use articles to schedule updates on the home page The need to schedule content changes in Shopify is something that apps are great at since the API gives many options for changes in content, and theme. Now if you're feeling a little DIY and want to build in something…
- Detect if a collection is published with Liquid Generally a hidden collection won't be accessible in Liquid, but it is when referenced via a menu (linklist). It's important that your code can handle this possibility and skips the hidden collection in your loop -…
- Translate a Liquid date string in Shopify Shopify Liquid has allows you to change the formatting of the date string but the default output is English. If you want to change the days or months to be shown in another language you'll need to translate it. Let's…
- Translating tax string VAT to BTW for Shopify notifications Talking to merchants around the world lets you learn about the many unique ways they need to run their stores . On example of this is a recent email I had from a merchant in the Netherlands that wanted to show BTW…
- How to change the order of products shown in the Admin There was a recent post on the Shopify eCommerce forums where someone asked how to change the sort order of products in the Admin (not the storefront). I can actually see the use case for this but thankfully a simple…
- Add a persistent cart to Shopify without apps Persistent cart is an interesting concept: On one hand I like the idea of a session that expires with the device I am using. On the other I see why merchants may want a cart that acts more like a saved wishlist. Let's…
- Get shipping estimates on a product page Getting a shipping estimate for a single product on Shopify is tough since you need to first add it to the cart. With some JavaScript - and a little bit of cart cookie modification - we can add this feature in to any…
- Get Shopify cart contents cross domain via jsonp If you're someone that has a Shopify site but runs an offsite blog (like wordpress) you'll probably want to be able to show the cart contents on that blog. The usual AJAX API calls won't work since you'll hit CORS…
- Experimenting with exporting orders from Shopify to a PDF There's a great JavaScript library for generating PDF files that I've always wanted to build something with. The output won't be anywhere near as pretty as using Scripting for Adobe Indesign but could be a good fit to…
- Get the current domain being used with Liquid If you have multiple domains attached to your Shopify store you might want to detect what one is currently being used. You might need this is if you want to show certain content if the Australian domain is used versus…
- Using Shopify Scripts to remove an applied discount code Shopify Scripts is a great (and fun) feature available for Shopify Plus merchants. There's lots of interesting things you can do with Scripts, with one being the ability to remove a discount code from the cart…
- Detect the search type used in a Shopify search with Liquid There'll be times that you might want to use the "type" setting for a Shopify storefront search to change how content is shown in search.liquid. Let's look at some quick code to the type value.
- Get the url querystring values with Liquid in Shopify There's no built in Liquid method to return the querystring values in a url with Shopify Liquid. There is a hacky way to get those values right now but it's far from being something I'd want to see used on a live…
- Why I use a snippet for my password page layouts If I was designing a password template for a client I'd generally always add the code for that page into a snippet. The reason is pretty simple - it makes it a lot easier to preview the design without locking the store.
- Exceeded maximum number of unique handles for all_products If you've found this post by the power of Google it means that you're doing cool things with Shopify Liquid, but you've hit an error. Let's talk quickly about the limit.