web.dev
web.dev is the ultimate resource for developers of all backgrounds to learn, create, and solve on the web. It's meant to not only educate developers, but help them apply what they've learned to any site they work on, be it personal or business.
👷♀️
Found a bug? Thanks for letting us know! Please file an issue and a team member should reply shortly.
✍️
Authoring content Before you start writing take a moment to look over the web.dev handbook and familiarize yourself with the process. When you're ready, follow the steps in the Quickstart to create your content proposal.
🏗
Building the site You'll need a recent version of Node: v14 (LTS) or higher. To check your node version run node -v
in your terminal.
If you don't have node, or if you need to upgrade, we recommend using the Node Version Manager (nvm).
Clone the repo
git clone https://github.com/GoogleChrome/web.dev.git
Change directory into the folder created
cd web.dev
Install dependencies
npm ci
Start a local server to preview the site
npm run dev
Open http://localhost:8080/
to see the site locally. Changes to assets will rebuild the site. Refresh to see your changes.
Set up build flags
Building the entire site can take a while because it's around one thousand pages. If you want to massively speed up your build times, we suggest setting some build flags to ignore certain sections.
- Create a
.env
file at the root of your project - Add the following:
# Ignore ALL site content
ELEVENTY_IGNORE=true
# Only build the directories you're working on.
# Note, this is a JSON string so you must use double quotes.
ELEVENTY_INCLUDE=["blog", "vitals"]
🌳
Environments Set ELEVENTY_ENV=prod
to force production builds. This is the default when running "stage" or "deploy". No other options for ELEVENTY_ENV
are supported, although our Eleventy site config will default to 'dev' if unspecified.
🕺
Staging When you send in a pull request it will be automatically staged for you. Keep an eye out for the netlify bot to comment on the pull request with your unique URL.
🚀
Deploying the site Automatic deploys
The site will build and deploy the main branch automatically every hour, Mon-Fri. If you've just merged an article then it should go live at the top of the next hour.
Manual deploys
To manually deploy the site you'll need to be a member of one of these Google teams:
- web.dev-eng
- web.dev-owners
- Navigate to the Cloud Build Triggers page.
- Click the RUN button for the trigger named Deploy.
- In the side drawer that opens up, click the RUN TRIGGER button for the trigger for the main branch.
NOTE: web.dev auto deploys every hour if there is a new commit in the main
branch. Manual deploys should only occur when a build fails or if auto deploys are disabled.
🐛
Debugging If you need to debug the site's build process:
- Add a
debugger
statement to.eleventy.js
- Run
npm run debug:eleventy
- Go to
about://inspect
to attach to the running process.
Update variable fonts article
This is an update to Introduction to variable fonts on the web by @davelab6 and @roeln. Dave and I paired on this, and I added some animations afterwards, and now submitting this PR.
This PR needs one more revision by @davelab6 to address the last TODOs.
Changes proposed in this pull request:
@font-face
code examplesfont-variation-settings
TODO:
Podcast lander page
web.dev/podcasts
Screenshot
todo list:
<a>
around the whole card so that talent names can link to profiles, other shows, etcAdds native lazy loading blog post
Fixes #1059, #1120
This PR adds the lazy loading post to /blog
Need to include (and can do so later once they land):
NOTE: Plan is to hold off merging this article until things are settled with regards to which release the spec-revised version of lazyload ends up landing (76 or 77).
content: How to request new browser features [title tbd.]
Author: @tomayac Reviewer: @kaycebasques
Target publish date: any
[ ] Check this box if this is a hard deadline.
[X] Check this box if you'd like your reviewer to fix grammar and punctuation issues for you.
Quick summary: Web developers are asking how they can make their voice heard and request a feature to be implemented by the different browser vendors. This article will be an attempt at documenting the best way for each vendor to make this happen.
Process
Check out the web.dev writing process.
When you're ready, make a copy of this template and fill in the proposal and outline sections. When you're finished, drop a link to the doc in the 1st step below and check the box. A member of the web.dev team will assign this ticket to themselves and work as your reviewer to help you complete the remaining steps.
Why is 'initial response time was short' an issue?
I'm trying to figure out what the message "initial server response time was short" means. To me, this sounds like undeniably a good thing, but then why does it show up a as performance issue? The issue links to Reduce server response times (TTFB).
Does this mean that there is a lot of latency when establishing the connecting to the server? If so, I think the wording should be "initial server response time was slow" or "initial server response time was long".
I've looked at the discussion in the pull request, but I am still confused.
content: Preloading responsive images
Author: @yoavweiss Reviewer: @mihajlija
Proposed article
A one to two sentence description of your post This post will explain the recently shipped responsive image preload feature, how to use it and its benefits.
Target publish date: 8/14/2019
Process Make a copy of this template and fill in the proposal and outline sections. When you're finished, drop a link to the doc in the 1st step below and check the box. A member of the web.dev team will assign this ticket to themselves and work as your reviewer to help you complete the remaining steps.
"Building multiple Progressive Web Apps on the same domain" article.
Fixes #5164
@jpmedley article is ready for review. We are still waiting for the assets of the other two authors before merging.
cc // @petele @kaycebasques
Move async article from WebFu.
Fixes #4437
Changes proposed in this pull request:
📦 NEW: Codelab Cloudinary URL API
Fixes #1065
This PR adds a new codelab:
Optimize images and serve next-gen formats using Cloudinary
After discussion with @khempenius and @traderd65 after Google I/O. I went ahead and created this new Codelab to demonstrate how the cloud can help developers avoid a build step and optimize their media both in terms of
All of that on the basis of a simple URL API.
Things I have done while creating this codelab:
Looking forward to the review/merge.
Peace! ✌️
Add Web Payments collection to /learn
Fixes #2979
This is a part of larger Web Payments doc set. The first four docs included in this PR:
Reviewed by @mihajlija
@kaycebasques can you create an issue for Web Payments?
Updates "SameSite cookies explainer" and adds "SameSite cookies recipes"
Fixes: #1460
Updates to the http://web.dev/samesite-cookies-explained article.
Changes proposed in this pull request:
SameSite
is a platform change, not a Chrome changecontent: TODO
What page(s) need to be updated?
Provide a list of URLs.
Why is this update needed?
What's the deadline?
Is it a hard deadline?
If yes, please explain why.
Example link not working
Describe the bug The example in this page/section doesn't work
To Reproduce Steps to reproduce the behavior:
example
Expected behavior The example should be present.
Screenshots If applicable, add screenshots to help explain your problem.
Duplicate content on enabling https
I am assuming this happened during the migration, but we appear to have a duplicate article:
The second is most recently updated and seems to get the most traffic. So we should remove the first and redirect to the second.
Added step to place secret within workflow
Fixes #9360
Changes proposed in this pull request:
Individual CLA signed, Mark Vogelgesang
content: Automation with LHCI
What page(s) need to be updated?
https://web.dev/lighthouse-ci/
Why is this update needed?
Instructions miss a step to add repository secret that is required for the Status Check to work correctly
What's the deadline?
none
chore(content): clarify meaning of LightWallet
When reading the article and clicking on the link to LightWallet, my first reaction was that the link was incorrectly marked up.
In its current state, it links to the article the reader is reading. This was not what I was expecting. After reading the article, I realized that LightWallet is the name used to define and test against a predefined performance budget with the Lighthouse CLI.
The update here attempts to clarify this upfront and removes the link to avoid confusion.