SShortSingh.
Back to feed

Shopify's Ruby Liquid Engine and LiquidJS Differ Enough to Break Live Storefronts

0
·1 views

Shopify's storefront renders Liquid templates using its own Ruby-based engine, while most local development tools — including Shopify Theme Check and Node-based simulators — use LiquidJS, a separate JavaScript reimplementation. The two engines agree on most syntax but diverge on whitespace handling, particularly around trimming markers like {%- and -%}, which can produce different output. This discrepancy becomes critical when rendered whitespace is treated as data, such as when splitting strings on delimiters to build table rows, SVG paths, or JSON blobs. A developer documented how a size chart metafield rendered correctly in local preview but broke on the live storefront due to this mismatch. The recommended approach is to use local linting for syntax and schema validation, but always verify whitespace-sensitive output directly on a Shopify dev store or theme preview.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingHacker News ·

Refactoring Guru shares lessons from 15 years of product development

Refactoring Guru has published a reflective piece on the journey of building and refining a product over 15 years. The article explores the long-term dedication required to perfect a software-focused educational resource. It offers insights into the iterative process of continuous improvement and sustained commitment. The piece is aimed at developers and creators interested in the craft of long-term product building.

0
ProgrammingHacker News ·

GOES-19 Weather Satellite Enters Safe Hold Mode, Operations Paused

GOES-19, a U.S. weather satellite operated by NOAA, has entered Safe Hold mode, temporarily suspending its normal operations. Safe Hold is a protective state that satellites automatically engage when onboard systems detect an anomaly or potential issue. The event was reported via the Space Weather Government portal, indicating official acknowledgment of the situation. The cause and duration of the Safe Hold have not yet been publicly detailed. Authorities are expected to assess the satellite's status and work toward restoring normal functionality.

0
ProgrammingHacker News ·

Developer Launches Hilo: A Word Game Built Around Binary Search Logic

A developer has released Hilo, a browser-based word game that applies the concept of binary search to gameplay. The game challenges players to guess a target word by narrowing down possibilities using higher/lower style feedback, mimicking how binary search algorithms work. It was shared on Hacker News as a personal project under the 'Show HN' category. The game is accessible at hilogame.cc and appears to be an independent, hobby-driven creation. The post attracted minimal early engagement, with just a few points and no comments at the time of publication.

0
ProgrammingDEV Community ·

SlaveCode Code Execution Platform Earns Spot in Official Judge0 README Showcase

SlaveCode, an online platform that compiles and executes user-submitted code in real time, has been added to the official README showcase of Judge0, a widely used open-source code execution engine. Judge0's creator, Herman Zvonimir Došilović, discovered the project and opened a GitHub issue to express his appreciation before adding it to the showcase. SlaveCode uses Judge0 as its core execution engine, running it on isolated Microsoft Azure VMs that are physically separated from the platform's main API and databases hosted on Google Cloud Platform. This architectural separation is designed to contain any potential security breach within the execution sandbox, keeping user data and core infrastructure secure. The developer credited detailed public documentation of SlaveCode's architecture on Dev.to as the likely reason the project came to Došilović's attention.

Shopify's Ruby Liquid Engine and LiquidJS Differ Enough to Break Live Storefronts · ShortSingh