shopify-accelerate-app 1.0.53 → 1.0.54

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shopify-accelerate-app",
3
- "version": "1.0.53",
3
+ "version": "1.0.54",
4
4
  "description": "Shopify App development with full Typescript Support",
5
5
  "author": "Felix Tellmann",
6
6
  "license": "MIT",
@@ -292,17 +292,14 @@ export const generateLiquidFiles = (final?: boolean, cssOutput?: string) => {
292
292
  encoding: "utf-8",
293
293
  }) ?? "{}"
294
294
  );
295
+ const mergedTranslations = mergeLocales(translations, defaultSourceTranslations);
295
296
 
296
297
  const translationsJs = `<script>
297
- window.__listify_translations = ${JSON.stringify(
298
- mergeLocales(transformTranslations(translations), transformTranslations(defaultSourceTranslations)),
299
- undefined,
300
- 2
301
- )};
298
+ window.__listify_translations = ${JSON.stringify(transformTranslations(mergedTranslations), undefined, 2)};
302
299
  </script>
303
300
  `;
304
301
 
305
- const translationTypes = `export type Translations = ${JSON.stringify(translations, undefined, 2)
302
+ const translationTypes = `export type Translations = ${JSON.stringify(mergedTranslations, undefined, 2)
306
303
  .replace(/(\s+)([^\n:]*):([^\n{]*?),?\n/gi, "$1/* $3 */\n$1$2: string;\n")
307
304
  .replace(/"/gi, "")
308
305
  .replace(/,/gi, ";")
@@ -317,7 +314,7 @@ declare global {
317
314
 
318
315
  writeCompareFile(
319
316
  path.join(process.cwd(), extension_path, "locales", "en.default.json"),
320
- JSON.stringify(mergeLocales(translations, defaultSourceTranslations), undefined, 2)
317
+ JSON.stringify(mergedTranslations, undefined, 2)
321
318
  );
322
319
  writeCompareFile(path.join(process.cwd(), extension_path, "snippets", "translations.liquid"), translationsJs);
323
320
  writeCompareFile(path.join(folders.snippets, "translations.liquid"), translationsJs);