Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App metafield/metaobject namespace not working on the Shopify Editor, works okay in live. #2605

Closed
muchisx opened this issue Jan 29, 2025 · 4 comments
Labels
bug Something isn't working

Comments

@muchisx
Copy link

muchisx commented Jan 29, 2025

Please list the package(s) involved in the issue, and include the version you are using

	"@shopify/ui-extensions": "2024.10.x",
	"@shopify/ui-extensions-react": "2024.10.x",

Describe the bug

App-abreviated namespaces such as $app:my-app work for requesting metafields/metaobjects in the live version of extensions, but not in the editor.

This is the case for both StorefrontApi and Customer Account Api (for customer acc extensions)

Steps to reproduce the behavior:

  1. Define a metafield in the Shop resource with an app reserved namespace. eg $app:my-app and whatever key+type+value.
  2. In a checkout or customer account extension, request that metafield via the StorefrontApi or the CustomerAccount extensions using the app reserved namespace syntax from before $app:my-app
  3. Analyze the payload in the editor and in the Live preview
  4. No problems in the live preview, metafield will be found.
  5. Problems in the editor, the metafield is not found, is null.

Expected behavior

App reserved namespaces should work both in the editor and in the live preview

@muchisx muchisx added the bug Something isn't working label Jan 29, 2025
@omarcv07
Copy link

I'm experiencing the same issue. This is a critical bug

@gil--
Copy link
Member

gil-- commented Jan 31, 2025

This is expected. App owned metafields are not yet officially supported and will come later in Q1 per our public roadmap: https://shopify.dev/docs/apps/build/checkout#ui-extensions.

Closing this as we'll post updates to #1138 when official support arrives.

@gil-- gil-- closed this as completed Jan 31, 2025
@muchisx
Copy link
Author

muchisx commented Jan 31, 2025

@gil--

This is not an app owned metafield per sé.

As described, this is a Shop owned metafield which is very much supported, as it works 100% in the preview, as stated in the description.

The only problem is in the editor

@gil--
Copy link
Member

gil-- commented Jan 31, 2025

@muchisx I believe we're talking about the same thing: https://shopify.dev/docs/apps/build/custom-data/ownership#reserved-prefixes. Reserved prefixes (aka $app) are not officially supported in checkout today.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants