-
Notifications
You must be signed in to change notification settings - Fork 144
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #5109 from Shopify/theme-profile
Add `theme profile` command
- Loading branch information
Showing
33 changed files
with
1,655 additions
and
24 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@shopify/theme': minor | ||
--- | ||
|
||
Add `theme profile` command which allows users to get a performance profile for Liquid rendering on a given page |
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 @@ | ||
theme profile | ||
|
||
theme profile --url /products/classic-leather-jacket |
56 changes: 56 additions & 0 deletions
56
docs-shopify.dev/commands/interfaces/theme-profile.interface.ts
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 @@ | ||
// This is an autogenerated file. Don't edit this file manually. | ||
export interface themeprofile { | ||
/** | ||
* The environment to apply to the current command. | ||
* @environment SHOPIFY_FLAG_ENVIRONMENT | ||
*/ | ||
'-e, --environment <value>'?: string | ||
|
||
/** | ||
* Output the result as JSON. | ||
* @environment SHOPIFY_FLAG_JSON | ||
*/ | ||
'-j, --json'?: '' | ||
|
||
/** | ||
* Disable color output. | ||
* @environment SHOPIFY_FLAG_NO_COLOR | ||
*/ | ||
'--no-color'?: '' | ||
|
||
/** | ||
* Password generated from the Theme Access app. | ||
* @environment SHOPIFY_CLI_THEME_TOKEN | ||
*/ | ||
'--password <value>'?: string | ||
|
||
/** | ||
* Store URL. It can be the store prefix (example) or the full myshopify.com URL (example.myshopify.com, https://example.myshopify.com). | ||
* @environment SHOPIFY_FLAG_STORE | ||
*/ | ||
'-s, --store <value>'?: string | ||
|
||
/** | ||
* The password for storefronts with password protection. | ||
* @environment SHOPIFY_FLAG_STORE_PASSWORD | ||
*/ | ||
'--store-password <value>'?: string | ||
|
||
/** | ||
* Theme ID or name of the remote theme. | ||
* @environment SHOPIFY_FLAG_THEME_ID | ||
*/ | ||
'-t, --theme <value>'?: string | ||
|
||
/** | ||
* The url to be used as context | ||
* @environment SHOPIFY_FLAG_URL | ||
*/ | ||
'--url <value>'?: string | ||
|
||
/** | ||
* Increase the verbosity of the output. | ||
* @environment SHOPIFY_FLAG_VERBOSE | ||
*/ | ||
'--verbose'?: '' | ||
} |
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,36 @@ | ||
// This is an autogenerated file. Don't edit this file manually. | ||
import {ReferenceEntityTemplateSchema} from '@shopify/generate-docs' | ||
|
||
const data: ReferenceEntityTemplateSchema = { | ||
name: 'theme profile', | ||
description: `Profile the Shopify Liquid on a given page. | ||
This command will open a web page with the Speedscope profiler detailing the time spent executing Liquid on the given page.`, | ||
overviewPreviewDescription: `Profile the Liquid rendering of a theme page.`, | ||
type: 'command', | ||
isVisualComponent: false, | ||
defaultExample: { | ||
codeblock: { | ||
tabs: [ | ||
{ | ||
title: 'theme profile', | ||
code: './examples/theme-profile.example.sh', | ||
language: 'bash', | ||
}, | ||
], | ||
title: 'theme profile', | ||
}, | ||
}, | ||
definitions: [ | ||
{ | ||
title: 'Flags', | ||
description: 'The following flags are available for the `theme profile` command:', | ||
type: 'themeprofile', | ||
}, | ||
], | ||
category: 'theme', | ||
related: [ | ||
], | ||
} | ||
|
||
export default data |
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
Oops, something went wrong.