-
Notifications
You must be signed in to change notification settings - Fork 323
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Matt Seccafien
committed
Apr 26, 2022
1 parent
fbdac54
commit f058c19
Showing
71 changed files
with
3,478 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,7 @@ | |
"private": true, | ||
"packageManager": "[email protected]", | ||
"workspaces": [ | ||
"examples/template-hydrogen-default", | ||
"templates/*", | ||
"packages/*", | ||
"packages/playground/*" | ||
], | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
templates/template-hydrogen-default/.devcontainer/devcontainer.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
{ | ||
"name": "Shopify Hydrogen", | ||
"image": "mcr.microsoft.com/vscode/devcontainers/javascript-node:0-16", | ||
"settings": {}, | ||
"extensions": [ | ||
"graphql.vscode-graphql", | ||
"dbaeumer.vscode-eslint", | ||
"bradlc.vscode-tailwindcss", | ||
"esbenp.prettier-vscode" | ||
], | ||
"forwardPorts": [3000], | ||
"postCreateCommand": "yarn install", | ||
"postStartCommand": "yarn dev", | ||
"remoteUser": "node", | ||
"features": { | ||
"git": "latest" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
module.exports = { | ||
extends: ['plugin:hydrogen/recommended'], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
|
||
node_modules | ||
.DS_Store | ||
dist | ||
dist-ssr | ||
*.local | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"installDependencies": true, | ||
"startCommand": "npm run dev" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
module.exports = { | ||
extends: ['@shopify/stylelint-plugin', '@shopify/stylelint-plugin/prettier'], | ||
rules: { | ||
'at-rule-no-unknown': [ | ||
true, | ||
{ | ||
ignoreAtRules: ['tailwind', 'layer'], | ||
}, | ||
], | ||
'selector-type-no-unknown': [ | ||
true, | ||
{ | ||
ignoreTypes: ['model-viewer'], | ||
}, | ||
], | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{ | ||
"recommendations": [ | ||
"graphql.vscode-graphql", | ||
"dbaeumer.vscode-eslint", | ||
"esbenp.prettier-vscode", | ||
"bradlc.vscode-tailwindcss" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# Hydrogen App | ||
|
||
Hydrogen is a React framework and SDK that you can use to build fast and dynamic Shopify custom storefronts. | ||
|
||
[Check out the docs](https://shopify.dev/custom-storefronts/hydrogen) | ||
|
||
## Getting started | ||
|
||
**Requirements:** | ||
|
||
- Node.js version 16.5.0 or higher | ||
- Yarn | ||
|
||
```bash | ||
yarn | ||
yarn dev | ||
``` | ||
|
||
Remember to update `shopify.config.js` with your shop's domain and Storefront API token! | ||
|
||
## Previewing a production build | ||
|
||
To run a local preview of your Hydrogen app in an environment similar to Oxygen, build your Hydrogen app and then run `yarn preview`: | ||
|
||
```bash | ||
yarn build | ||
yarn preview | ||
``` | ||
|
||
## Building for production | ||
|
||
```bash | ||
yarn build | ||
``` | ||
|
||
Then, you can run a local `server.js` using the production build with: | ||
|
||
```bash | ||
yarn serve | ||
``` | ||
|
||
## Running tests | ||
|
||
This project contains basic end-to-end (E2E) tests in the `/tests/e2e` folder powered by [Vitest](https://vitest.dev). | ||
|
||
You can run tests in development, and they will automatically reload when you make changes to the component you provide to `hydrogen.watchForUpdates()`: | ||
|
||
```bash | ||
yarn test | ||
``` | ||
|
||
To run tests in a continuous-integration (CI) environment like GitHub Actions: | ||
|
||
```bash | ||
yarn test:ci | ||
``` |
Oops, something went wrong.