@shopify/cli-hydrogen 4.1.0 → 4.1.2

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.
Files changed (55) hide show
  1. package/dist/commands/hydrogen/dev.d.ts +1 -0
  2. package/dist/commands/hydrogen/dev.js +8 -0
  3. package/dist/commands/hydrogen/env/pull.d.ts +21 -0
  4. package/dist/commands/hydrogen/env/pull.js +115 -0
  5. package/dist/commands/hydrogen/env/pull.test.d.ts +1 -0
  6. package/dist/commands/hydrogen/env/pull.test.js +205 -0
  7. package/dist/commands/hydrogen/init.js +3 -1
  8. package/dist/commands/hydrogen/link.d.ts +24 -0
  9. package/dist/commands/hydrogen/link.js +102 -0
  10. package/dist/commands/hydrogen/link.test.d.ts +1 -0
  11. package/dist/commands/hydrogen/link.test.js +137 -0
  12. package/dist/commands/hydrogen/list.d.ts +21 -0
  13. package/dist/commands/hydrogen/list.js +83 -0
  14. package/dist/commands/hydrogen/list.test.d.ts +1 -0
  15. package/dist/commands/hydrogen/list.test.js +116 -0
  16. package/dist/commands/hydrogen/unlink.d.ts +17 -0
  17. package/dist/commands/hydrogen/unlink.js +29 -0
  18. package/dist/commands/hydrogen/unlink.test.d.ts +1 -0
  19. package/dist/commands/hydrogen/unlink.test.js +36 -0
  20. package/dist/generator-templates/routes/[robots.txt].tsx +111 -19
  21. package/dist/generator-templates/routes/collections/index.tsx +102 -0
  22. package/dist/lib/admin-session.d.ts +5 -0
  23. package/dist/lib/admin-session.js +16 -0
  24. package/dist/lib/admin-session.test.d.ts +1 -0
  25. package/dist/lib/admin-session.test.js +27 -0
  26. package/dist/lib/admin-urls.d.ts +8 -0
  27. package/dist/lib/admin-urls.js +18 -0
  28. package/dist/lib/flags.d.ts +1 -0
  29. package/dist/lib/flags.js +7 -0
  30. package/dist/lib/graphql/admin/link-storefront.d.ts +11 -0
  31. package/dist/lib/graphql/admin/link-storefront.js +11 -0
  32. package/dist/lib/graphql/admin/list-storefronts.d.ts +17 -0
  33. package/dist/lib/graphql/admin/list-storefronts.js +16 -0
  34. package/dist/lib/graphql/admin/pull-variables.d.ts +16 -0
  35. package/dist/lib/graphql/admin/pull-variables.js +15 -0
  36. package/dist/lib/graphql.d.ts +21 -0
  37. package/dist/lib/graphql.js +18 -0
  38. package/dist/lib/graphql.test.d.ts +1 -0
  39. package/dist/lib/graphql.test.js +15 -0
  40. package/dist/lib/missing-routes.d.ts +3 -1
  41. package/dist/lib/missing-routes.js +7 -6
  42. package/dist/lib/missing-routes.test.d.ts +1 -0
  43. package/dist/lib/missing-routes.test.js +45 -0
  44. package/dist/lib/missing-storefronts.d.ts +5 -0
  45. package/dist/lib/missing-storefronts.js +18 -0
  46. package/dist/lib/shop.d.ts +7 -0
  47. package/dist/lib/shop.js +32 -0
  48. package/dist/lib/shop.test.d.ts +1 -0
  49. package/dist/lib/shop.test.js +78 -0
  50. package/dist/lib/shopify-config.d.ts +35 -0
  51. package/dist/lib/shopify-config.js +86 -0
  52. package/dist/lib/shopify-config.test.d.ts +1 -0
  53. package/dist/lib/shopify-config.test.js +209 -0
  54. package/oclif.manifest.json +1 -1
  55. package/package.json +4 -4
@@ -0,0 +1,209 @@
1
+ import { describe, it, expect } from 'vitest';
2
+ import { inTemporaryDirectory, mkdir, writeFile, fileExists, readFile } from '@shopify/cli-kit/node/fs';
3
+ import { joinPath, dirname } from '@shopify/cli-kit/node/path';
4
+ import { getConfig, SHOPIFY_DIR, SHOPIFY_DIR_PROJECT, setShop, setStorefront, unsetStorefront, ensureShopifyGitIgnore } from './shopify-config.js';
5
+
6
+ describe("getConfig()", () => {
7
+ describe("when no config exists", () => {
8
+ it("returns an empty object", async () => {
9
+ await inTemporaryDirectory(async (tmpDir) => {
10
+ const config = await getConfig(tmpDir);
11
+ expect(config).toStrictEqual({});
12
+ });
13
+ });
14
+ });
15
+ describe("when a config exists", () => {
16
+ it("returns the config", async () => {
17
+ await inTemporaryDirectory(async (tmpDir) => {
18
+ const existingConfig = {
19
+ shop: "my-shop"
20
+ };
21
+ const filePath = joinPath(tmpDir, SHOPIFY_DIR, SHOPIFY_DIR_PROJECT);
22
+ await mkdir(dirname(filePath));
23
+ await writeFile(filePath, JSON.stringify(existingConfig));
24
+ const config = await getConfig(tmpDir);
25
+ expect(config).toStrictEqual(existingConfig);
26
+ });
27
+ });
28
+ });
29
+ });
30
+ describe("setShop()", () => {
31
+ describe("when no config exists", () => {
32
+ it("creates a new config file", async () => {
33
+ await inTemporaryDirectory(async (tmpDir) => {
34
+ const filePath = joinPath(tmpDir, SHOPIFY_DIR, SHOPIFY_DIR_PROJECT);
35
+ expect(await fileExists(filePath)).toBeFalsy();
36
+ await setShop(tmpDir, "new-shop");
37
+ expect(await fileExists(filePath)).toBeTruthy();
38
+ });
39
+ });
40
+ it("returns the new config", async () => {
41
+ await inTemporaryDirectory(async (tmpDir) => {
42
+ const config = await setShop(tmpDir, "new-shop");
43
+ expect(config).toStrictEqual({
44
+ shop: "new-shop"
45
+ });
46
+ });
47
+ });
48
+ });
49
+ describe("when a config exists", () => {
50
+ it("updates the config file", async () => {
51
+ await inTemporaryDirectory(async (tmpDir) => {
52
+ const existingConfig = {
53
+ shop: "previous-shop",
54
+ storefront: {
55
+ id: "gid://shopify/HydrogenStorefront/1",
56
+ title: "Hydrogen"
57
+ }
58
+ };
59
+ const filePath = joinPath(tmpDir, SHOPIFY_DIR, SHOPIFY_DIR_PROJECT);
60
+ await mkdir(dirname(filePath));
61
+ await writeFile(filePath, JSON.stringify(existingConfig));
62
+ expect(JSON.parse(await readFile(filePath))).toStrictEqual(
63
+ existingConfig
64
+ );
65
+ await setShop(tmpDir, "new-shop");
66
+ expect(JSON.parse(await readFile(filePath))).toStrictEqual({
67
+ ...existingConfig,
68
+ shop: "new-shop"
69
+ });
70
+ });
71
+ });
72
+ it("returns the new config", async () => {
73
+ await inTemporaryDirectory(async (tmpDir) => {
74
+ const existingConfig = {
75
+ shop: "previous-shop",
76
+ storefront: {
77
+ id: "gid://shopify/HydrogenStorefront/1",
78
+ title: "Hydrogen"
79
+ }
80
+ };
81
+ const filePath = joinPath(tmpDir, SHOPIFY_DIR, SHOPIFY_DIR_PROJECT);
82
+ await mkdir(dirname(filePath));
83
+ await writeFile(filePath, JSON.stringify(existingConfig));
84
+ const config = await setShop(tmpDir, "new-shop");
85
+ expect(config).toStrictEqual({
86
+ ...existingConfig,
87
+ shop: "new-shop"
88
+ });
89
+ });
90
+ });
91
+ });
92
+ });
93
+ describe("setStorefront()", () => {
94
+ it("updates the config file", async () => {
95
+ await inTemporaryDirectory(async (tmpDir) => {
96
+ const existingConfig = {
97
+ shop: "previous-shop",
98
+ storefront: {
99
+ id: "gid://shopify/HydrogenStorefront/1",
100
+ title: "Hydrogen"
101
+ }
102
+ };
103
+ const filePath = joinPath(tmpDir, SHOPIFY_DIR, SHOPIFY_DIR_PROJECT);
104
+ await mkdir(dirname(filePath));
105
+ await writeFile(filePath, JSON.stringify(existingConfig));
106
+ expect(JSON.parse(await readFile(filePath))).toStrictEqual(
107
+ existingConfig
108
+ );
109
+ const newStorefront = {
110
+ id: "gid://shopify/HydrogenStorefront/2",
111
+ title: "Remix"
112
+ };
113
+ await setStorefront(tmpDir, newStorefront);
114
+ expect(JSON.parse(await readFile(filePath))).toStrictEqual({
115
+ ...existingConfig,
116
+ storefront: newStorefront
117
+ });
118
+ });
119
+ });
120
+ it("returns the new config", async () => {
121
+ await inTemporaryDirectory(async (tmpDir) => {
122
+ const existingConfig = {
123
+ shop: "previous-shop",
124
+ storefront: {
125
+ id: "gid://shopify/HydrogenStorefront/1",
126
+ title: "Hydrogen"
127
+ }
128
+ };
129
+ const filePath = joinPath(tmpDir, SHOPIFY_DIR, SHOPIFY_DIR_PROJECT);
130
+ await mkdir(dirname(filePath));
131
+ await writeFile(filePath, JSON.stringify(existingConfig));
132
+ const newStorefront = {
133
+ id: "gid://shopify/HydrogenStorefront/2",
134
+ title: "Remix"
135
+ };
136
+ const config = await setStorefront(tmpDir, newStorefront);
137
+ expect(config).toStrictEqual({
138
+ ...existingConfig,
139
+ storefront: newStorefront
140
+ });
141
+ });
142
+ });
143
+ });
144
+ describe("unsetStorefront()", () => {
145
+ it("removes the storefront configuration and returns the config", async () => {
146
+ await inTemporaryDirectory(async (tmpDir) => {
147
+ const existingConfig = {
148
+ shop: "previous-shop",
149
+ storefront: {
150
+ id: "gid://shopify/HydrogenStorefront/1",
151
+ title: "Hydrogen"
152
+ }
153
+ };
154
+ const filePath = joinPath(tmpDir, SHOPIFY_DIR, SHOPIFY_DIR_PROJECT);
155
+ await mkdir(dirname(filePath));
156
+ await writeFile(filePath, JSON.stringify(existingConfig));
157
+ expect(JSON.parse(await readFile(filePath))).toStrictEqual(
158
+ existingConfig
159
+ );
160
+ const config = await unsetStorefront(tmpDir);
161
+ expect(config).toStrictEqual({
162
+ shop: "previous-shop",
163
+ storefront: void 0
164
+ });
165
+ expect(JSON.parse(await readFile(filePath))).toStrictEqual({
166
+ shop: "previous-shop"
167
+ });
168
+ });
169
+ });
170
+ });
171
+ describe("ensureShopifyGitIgnore()", () => {
172
+ describe("when a .gitignore file already exists", () => {
173
+ it("updates the .gitignore file and returns true", async () => {
174
+ await inTemporaryDirectory(async (tmpDir) => {
175
+ const existingFileContents = "node_modules\r\n";
176
+ const filePath = joinPath(tmpDir, ".gitignore");
177
+ await writeFile(filePath, JSON.stringify(existingFileContents));
178
+ expect(await readFile(filePath)).not.toContain(".shopify");
179
+ const result = await ensureShopifyGitIgnore(tmpDir);
180
+ expect(await readFile(filePath)).toContain(".shopify");
181
+ expect(result).toBeTruthy();
182
+ });
183
+ });
184
+ describe("and the file is already ignoring .shopify", () => {
185
+ it("does not update the file and returns false", async () => {
186
+ await inTemporaryDirectory(async (tmpDir) => {
187
+ const existingFileContents = "node_modules\n.shopify\r\n";
188
+ const filePath = joinPath(tmpDir, ".gitignore");
189
+ await writeFile(filePath, JSON.stringify(existingFileContents));
190
+ const originalFile = await readFile(filePath);
191
+ const result = await ensureShopifyGitIgnore(tmpDir);
192
+ expect(await readFile(filePath)).toStrictEqual(originalFile);
193
+ expect(result).toBeFalsy();
194
+ });
195
+ });
196
+ });
197
+ });
198
+ describe("when a .gitignore does not exist", () => {
199
+ it("creates the .gitignore file and returns true", async () => {
200
+ await inTemporaryDirectory(async (tmpDir) => {
201
+ const filePath = joinPath(tmpDir, ".gitignore");
202
+ expect(await fileExists(filePath)).toBeFalsy();
203
+ const result = await ensureShopifyGitIgnore(tmpDir);
204
+ expect(await readFile(filePath)).toContain(".shopify");
205
+ expect(result).toBeTruthy();
206
+ });
207
+ });
208
+ });
209
+ });
@@ -1 +1 @@
1
- {"version":"4.1.0","commands":{"hydrogen:build":{"id":"hydrogen:build","description":"Builds a Hydrogen storefront for production.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false},"sourcemap":{"name":"sourcemap","type":"boolean","description":"Generate sourcemaps for the build.","allowNo":false},"disable-route-warning":{"name":"disable-route-warning","type":"boolean","description":"Disable warning about missing standard routes.","allowNo":false},"base":{"name":"base","type":"option","hidden":true,"multiple":false},"entry":{"name":"entry","type":"option","hidden":true,"multiple":false},"target":{"name":"target","type":"option","hidden":true,"multiple":false}},"args":[]},"hydrogen:check":{"id":"hydrogen:check","description":"Returns diagnostic information about a Hydrogen storefront.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false}},"args":[{"name":"resource","description":"The resource to check. Currently only 'routes' is supported.","required":true,"options":["routes"]}]},"hydrogen:dev":{"id":"hydrogen:dev","description":"Runs Hydrogen storefront in an Oxygen worker for development.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false},"port":{"name":"port","type":"option","description":"Port to run the server on.","multiple":false,"default":3000},"disable-virtual-routes":{"name":"disable-virtual-routes","type":"boolean","description":"Disable rendering fallback routes when a route file doesn't exist","allowNo":false},"host":{"name":"host","type":"option","hidden":true,"multiple":false}},"args":[]},"hydrogen:g":{"id":"hydrogen:g","description":"Shortcut for `hydrogen generate`. See `hydrogen generate --help` for more information.","strict":false,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","hidden":true,"aliases":[],"flags":{},"args":[]},"hydrogen:init":{"id":"hydrogen:init","description":"Creates a new Hydrogen storefront.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"force":{"name":"force","type":"boolean","char":"f","description":"Overwrite the destination directory and files if they already exist.","allowNo":false},"path":{"name":"path","type":"option","description":"The path to the directory of the new Hydrogen storefront.","multiple":false},"language":{"name":"language","type":"option","description":"Sets the template language to use. One of `js` or `ts`.","multiple":false},"template":{"name":"template","type":"option","description":"Sets the template to use. One of `demo-store` or `hello-world`.","multiple":false},"install-deps":{"name":"install-deps","type":"boolean","description":"Auto install dependencies using the active package manager","allowNo":true}},"args":[]},"hydrogen:preview":{"id":"hydrogen:preview","description":"Runs a Hydrogen storefront in an Oxygen worker for production.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false},"port":{"name":"port","type":"option","description":"Port to run the server on.","multiple":false,"default":3000}},"args":[]},"hydrogen:shortcut":{"id":"hydrogen:shortcut","description":"Creates a global `h2` shortcut for the Hydrogen CLI","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{},"args":[]},"hydrogen:generate:route":{"id":"hydrogen:generate:route","description":"Generates a standard Shopify route.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"adapter":{"name":"adapter","type":"option","description":"Remix adapter used in the route. The default is `@shopify/remix-oxygen`.","multiple":false},"typescript":{"name":"typescript","type":"boolean","description":"Generate TypeScript files","allowNo":false},"force":{"name":"force","type":"boolean","char":"f","description":"Overwrite the destination directory and files if they already exist.","allowNo":false},"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false}},"args":[{"name":"route","description":"The route to generate. One of home,page,cart,products,collections,policies,robots,sitemap,account,all.","required":true,"options":["home","page","cart","products","collections","policies","robots","sitemap","account","all"]}]},"hydrogen:generate:routes":{"id":"hydrogen:generate:routes","description":"Generates all supported standard shopify routes.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"adapter":{"name":"adapter","type":"option","description":"Remix adapter used in the route. The default is `@shopify/remix-oxygen`.","multiple":false},"typescript":{"name":"typescript","type":"boolean","description":"Generate TypeScript files","allowNo":false},"force":{"name":"force","type":"boolean","char":"f","description":"Overwrite the destination directory and files if they already exist.","allowNo":false},"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false}},"args":[]}}}
1
+ {"version":"4.1.2","commands":{"hydrogen:build":{"id":"hydrogen:build","description":"Builds a Hydrogen storefront for production.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false},"sourcemap":{"name":"sourcemap","type":"boolean","description":"Generate sourcemaps for the build.","allowNo":false},"disable-route-warning":{"name":"disable-route-warning","type":"boolean","description":"Disable warning about missing standard routes.","allowNo":false},"base":{"name":"base","type":"option","hidden":true,"multiple":false},"entry":{"name":"entry","type":"option","hidden":true,"multiple":false},"target":{"name":"target","type":"option","hidden":true,"multiple":false}},"args":[]},"hydrogen:check":{"id":"hydrogen:check","description":"Returns diagnostic information about a Hydrogen storefront.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false}},"args":[{"name":"resource","description":"The resource to check. Currently only 'routes' is supported.","required":true,"options":["routes"]}]},"hydrogen:dev":{"id":"hydrogen:dev","description":"Runs Hydrogen storefront in an Oxygen worker for development.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false},"port":{"name":"port","type":"option","description":"Port to run the server on.","multiple":false,"default":3000},"disable-virtual-routes":{"name":"disable-virtual-routes","type":"boolean","description":"Disable rendering fallback routes when a route file doesn't exist","allowNo":false},"debug":{"name":"debug","type":"boolean","description":"Attaches a Node inspector","allowNo":false},"host":{"name":"host","type":"option","hidden":true,"multiple":false}},"args":[]},"hydrogen:g":{"id":"hydrogen:g","description":"Shortcut for `hydrogen generate`. See `hydrogen generate --help` for more information.","strict":false,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","hidden":true,"aliases":[],"flags":{},"args":[]},"hydrogen:init":{"id":"hydrogen:init","description":"Creates a new Hydrogen storefront.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"force":{"name":"force","type":"boolean","char":"f","description":"Overwrite the destination directory and files if they already exist.","allowNo":false},"path":{"name":"path","type":"option","description":"The path to the directory of the new Hydrogen storefront.","multiple":false},"language":{"name":"language","type":"option","description":"Sets the template language to use. One of `js` or `ts`.","multiple":false},"template":{"name":"template","type":"option","description":"Sets the template to use. One of `demo-store` or `hello-world`.","multiple":false},"install-deps":{"name":"install-deps","type":"boolean","description":"Auto install dependencies using the active package manager","allowNo":true}},"args":[]},"hydrogen:link":{"id":"hydrogen:link","description":"Link a local project to one of your shop's Hydrogen storefronts.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","hidden":true,"aliases":[],"flags":{"force":{"name":"force","type":"boolean","char":"f","description":"Overwrite the destination directory and files if they already exist.","allowNo":false},"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false},"shop":{"name":"shop","type":"option","char":"s","description":"Shop URL. It can be the shop prefix (janes-apparel) or the full myshopify.com URL (janes-apparel.myshopify.com, https://janes-apparel.myshopify.com).","multiple":false},"storefront":{"name":"storefront","type":"option","char":"h","description":"The name of a Hydrogen Storefront (e.g. \"Jane's Apparel\")","multiple":false}},"args":[]},"hydrogen:list":{"id":"hydrogen:list","description":"Returns a list of Hydrogen storefronts available on a given shop.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","hidden":true,"aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false},"shop":{"name":"shop","type":"option","char":"s","description":"Shop URL. It can be the shop prefix (janes-apparel) or the full myshopify.com URL (janes-apparel.myshopify.com, https://janes-apparel.myshopify.com).","multiple":false}},"args":[]},"hydrogen:preview":{"id":"hydrogen:preview","description":"Runs a Hydrogen storefront in an Oxygen worker for production.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false},"port":{"name":"port","type":"option","description":"Port to run the server on.","multiple":false,"default":3000}},"args":[]},"hydrogen:shortcut":{"id":"hydrogen:shortcut","description":"Creates a global `h2` shortcut for the Hydrogen CLI","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{},"args":[]},"hydrogen:unlink":{"id":"hydrogen:unlink","description":"Unlink a local project from a Hydrogen storefront.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","hidden":true,"aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false}},"args":[]},"hydrogen:env:pull":{"id":"hydrogen:env:pull","description":"Populate your .env with variables from your Hydrogen storefront.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","hidden":true,"aliases":[],"flags":{"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false},"shop":{"name":"shop","type":"option","char":"s","description":"Shop URL. It can be the shop prefix (janes-apparel) or the full myshopify.com URL (janes-apparel.myshopify.com, https://janes-apparel.myshopify.com).","multiple":false},"force":{"name":"force","type":"boolean","char":"f","description":"Overwrite the destination directory and files if they already exist.","allowNo":false}},"args":[]},"hydrogen:generate:route":{"id":"hydrogen:generate:route","description":"Generates a standard Shopify route.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"adapter":{"name":"adapter","type":"option","description":"Remix adapter used in the route. The default is `@shopify/remix-oxygen`.","multiple":false},"typescript":{"name":"typescript","type":"boolean","description":"Generate TypeScript files","allowNo":false},"force":{"name":"force","type":"boolean","char":"f","description":"Overwrite the destination directory and files if they already exist.","allowNo":false},"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false}},"args":[{"name":"route","description":"The route to generate. One of home,page,cart,products,collections,policies,robots,sitemap,account,all.","required":true,"options":["home","page","cart","products","collections","policies","robots","sitemap","account","all"]}]},"hydrogen:generate:routes":{"id":"hydrogen:generate:routes","description":"Generates all supported standard shopify routes.","strict":true,"pluginName":"@shopify/cli-hydrogen","pluginAlias":"@shopify/cli-hydrogen","pluginType":"core","aliases":[],"flags":{"adapter":{"name":"adapter","type":"option","description":"Remix adapter used in the route. The default is `@shopify/remix-oxygen`.","multiple":false},"typescript":{"name":"typescript","type":"boolean","description":"Generate TypeScript files","allowNo":false},"force":{"name":"force","type":"boolean","char":"f","description":"Overwrite the destination directory and files if they already exist.","allowNo":false},"path":{"name":"path","type":"option","description":"The path to the directory of the Hydrogen storefront. The default is the current directory.","multiple":false}},"args":[]}}}
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "access": "public",
5
5
  "@shopify:registry": "https://registry.npmjs.org"
6
6
  },
7
- "version": "4.1.0",
7
+ "version": "4.1.2",
8
8
  "license": "SEE LICENSE IN LICENSE.md",
9
9
  "type": "module",
10
10
  "scripts": {
@@ -27,14 +27,14 @@
27
27
  },
28
28
  "peerDependencies": {
29
29
  "@remix-run/react": "^1.15.0",
30
- "@shopify/hydrogen-react": "^2023.1.8",
31
- "@shopify/remix-oxygen": "^1.0.5"
30
+ "@shopify/hydrogen-react": "^2023.4.1",
31
+ "@shopify/remix-oxygen": "^1.0.6"
32
32
  },
33
33
  "dependencies": {
34
34
  "@oclif/core": "2.1.4",
35
35
  "@remix-run/dev": "1.15.0",
36
36
  "@shopify/cli-kit": "3.45.0",
37
- "@shopify/mini-oxygen": "^1.3.1",
37
+ "@shopify/mini-oxygen": "^1.5.0",
38
38
  "ansi-colors": "^4.1.3",
39
39
  "fast-glob": "^3.2.12",
40
40
  "fs-extra": "^10.1.0",