question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Replace STORE_NAME usage with named constants

See original GitHub issue

For historical purposes we mix use of STORE_NAME and named constants for modules (like CORE_SITE or MODULES_ANALYTICS). But in files with multiple stores, the unnamed STORE_NAME provides little context, and now that the named constants are also available, we should replace all instances of STORE_NAME with the actual constant name (eg. CORE_SITE, CORE_USER, etc.)


Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

  • All instances of STORE_NAME throughout the code should be replaced with the “named constant” they represent.
  • Any other instances of STORE_NAME (for instance, in create-settings-store.js), should be renamed to something like settingsStoreName so they don’t invoke confusion for current developers because of the historical context of STORE_NAME. Using the constant formatting in this file isn’t really appropriate anyway. 🙂

Implementation Brief

Test Coverage

  • N/A

Visual Regression Changes

  • N/A

QA Brief

  • All unit tests and linting should continue to pass.
  • Verify no STORE_NAME constants are used/imported/exported from constants.js files.
  • Note that in many create-X-store.js files and tests there will be properties/internal variables with STORE_NAME values—these are separate and since they’re part of the API not worth changing here. They’re also internal and don’t cause the confusion this issue intended to fix 🙂

Changelog entry

  • N/A

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
wpdarrencommented, Aug 2, 2021

I feel this is a QA:Eng ticket but if I am incorrect then please feel free to let me know!

0reactions
asvinbcommented, Aug 4, 2021
  • Searched for the STORE_NAME throughout the codebase and no STORE_NAME constants are used/imported/exported from constants.js files. ☑️
  • STORE_NAME is only present in create-X-store.js files. ☑️

QA: ✅

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Change Shopify Store Name: 2021 Guide - Cart2Cart
The post explains how to change Shopify store name in a few simple steps without breaking anything on your eCommerce platform.
Read more >
Why does Kafka change store name - Stack Overflow
Use following: KTable<Long, byte[]> table = stream.groupByKey().aggregate(() -> null , (key, oldVal, newVal) -> { return newVal; } ...
Read more >
How to Use GraphQL Operation Names and Variables - Shopify
In this tutorial, we explore GraphQL operation names and variables for Shopify app development.
Read more >
Configuration files for distributed stores
storeName -spring.xml. * storeName-spring.properties. A distributed store is configured using a bean element in the Spring XML configuration file.
Read more >
Example C Program: Setting and Getting Certificate Store ...
In this article. The following example sets and gets a certificate store property, the localized store name. This property is not persisted ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found