You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+17-5Lines changed: 17 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@ If you would like to run the Lighthouse build plugin for multiple site paths, su
8
8
9
9
### Install plugin through the Netlify UI
10
10
11
-
You can install this plugin in the Netlify UI from this [direct in-app installation link](https://app.netlify.com/plugins/@netlify/plugin-lighthouse/install) or from the [Plugins directory](https://app.netlify.com/plugins).
11
+
You can install this plugin in the Netlify UI from this [direct in-app installation link](https://app.netlify.com/plugins/@netlify/plugin-lighthouse/install) or from the [Plugins directory](https://app.netlify.com/plugins).
12
12
13
13
### Install plugin through the `netlify.toml` file
14
14
@@ -71,22 +71,22 @@ Example `netlify.toml` file that audits the site root path and a contact page:
71
71
```
72
72
[[plugins]]
73
73
package = "@netlify/plugin-lighthouse"
74
-
74
+
75
75
# Generate a Lighthouse report for the site's root path
76
76
[[plugins.inputs.audits]]
77
77
path = ""
78
-
78
+
79
79
# Generate a Lighthouse report for the contact site path
80
80
[[plugins.inputs.audits]]
81
81
path = "contact"
82
82
83
83
```
84
84
85
-
86
85
The lighthouse report results are automatically printed to the **Deploy log** in the Netlify UI. For example:
2:35:07 PM: Serving and scanning site from directory dist
@@ -104,6 +104,17 @@ The lighthouse report results are automatically printed to the **Deploy log** in
104
104
2:35:17 PM: }
105
105
```
106
106
107
+
We currently support the following settings, which are passed directly to Lighthouse:
108
+
109
+
```
110
+
[[plugins]]
111
+
package = "@netlify/plugin-lighthouse"
112
+
113
+
[plugins.inputs.settings]
114
+
preset = "desktop" # Optionally run Lighthouse using a desktop configuration
115
+
locale = "es" # Any Lighthouse-supported locale, used to generate reports in a different language
116
+
```
117
+
107
118
## Running Locally
108
119
109
120
Fork and clone this repo.
@@ -126,6 +137,7 @@ If you have multiple audits (directories, paths, etc) defined in your build, we
126
137
<imgwidth="1400"alt="Deploy details with multiple audit Lighthouse results"src="https://user-images.githubusercontent.com/79875905/160019057-d29dffab-49f3-4fbf-a1ac-1f314e0cd837.png">
127
138
128
139
Some items of note:
140
+
129
141
- The [Lighthouse Build Plugin](https://app.netlify.com/plugins/@netlify/plugin-lighthouse/install) must be installed on your site(s) in order for these score visualizations to be displayed.
130
142
- This Labs feature is currently only enabled at the user-level, so it will need to be enabled for each individual team member that wishes to see the Lighthouse scores displayed.
0 commit comments