Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add last updated date to blog posts #692

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Pixel998
Copy link
Contributor

@Pixel998 Pixel998 commented Feb 8, 2025

Prerequisites checklist

What is the purpose of this pull request?

The purpose of the pull request is to add a "last updated" date to blog posts.

What changes did you make? (Give an overview)

I added a "last updated" date to each blog post.

localhost_2022_blog_2025_01_eslint-v9 18 0-released_

Related Issues

Fix #612

Is there anything you'd like reviewers to focus on?

Copy link

netlify bot commented Feb 8, 2025

Deploy Preview for pt-br-eslint ready!

Name Link
🔨 Latest commit 13596ba
🔍 Latest deploy log https://app.netlify.com/sites/pt-br-eslint/deploys/67ace66376c0f70008fccc7a
😎 Deploy Preview https://deploy-preview-692--pt-br-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Feb 8, 2025

Deploy Preview for ja-eslint ready!

Name Link
🔨 Latest commit 13596ba
🔍 Latest deploy log https://app.netlify.com/sites/ja-eslint/deploys/67ace663a0a041000845ad2d
😎 Deploy Preview https://deploy-preview-692--ja-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Feb 8, 2025

Deploy Preview for es-eslint ready!

Name Link
🔨 Latest commit 13596ba
🔍 Latest deploy log https://app.netlify.com/sites/es-eslint/deploys/67ace6634ba5fe000865f3b9
😎 Deploy Preview https://deploy-preview-692--es-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Feb 8, 2025

Deploy Preview for de-eslint ready!

Name Link
🔨 Latest commit 13596ba
🔍 Latest deploy log https://app.netlify.com/sites/de-eslint/deploys/67ace66376c0f70008fccc7c
😎 Deploy Preview https://deploy-preview-692--de-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Feb 8, 2025

Deploy Preview for zh-hans-eslint ready!

Name Link
🔨 Latest commit 13596ba
🔍 Latest deploy log https://app.netlify.com/sites/zh-hans-eslint/deploys/67ace66376c0f70008fccc76
😎 Deploy Preview https://deploy-preview-692--zh-hans-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Feb 8, 2025

Deploy Preview for fr-eslint ready!

Name Link
🔨 Latest commit 13596ba
🔍 Latest deploy log https://app.netlify.com/sites/fr-eslint/deploys/67ace6638c5c0900089c3a3a
😎 Deploy Preview https://deploy-preview-692--fr-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Feb 8, 2025

Deploy Preview for hi-eslint ready!

Name Link
🔨 Latest commit 13596ba
🔍 Latest deploy log https://app.netlify.com/sites/hi-eslint/deploys/67ace663dfae990008afb70c
😎 Deploy Preview https://deploy-preview-692--hi-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

netlify bot commented Feb 8, 2025

Deploy Preview for new-eslint ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 13596ba
🔍 Latest deploy log https://app.netlify.com/sites/new-eslint/deploys/67ace663cf7bd80008b9287f
😎 Deploy Preview https://deploy-preview-692--new-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link
Member

@nzakas nzakas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for taking a look at this.

Can you move the updated date/time to the left column? It doesn't look very good as another line at the top.

@@ -22,6 +22,7 @@ const path = require("node:path");
const fs = require("node:fs");
const yaml = require("js-yaml");
const { DateTime } = require("luxon");
const { execSync } = require("node:child_process");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there not some way built into Eleventy to get the updated date/time? This feels a bit heavy to me.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Pixel998
Copy link
Contributor Author

Can you move the updated date/time to the left column? It doesn't look very good as another line at the top.

Like so?
eslint org_blog_2025_02_eslint-v9 20 1-released_ (1)

@nzakas
Copy link
Member

nzakas commented Feb 12, 2025

Yes, that looks good. 👍

Copy link
Contributor

@Tanujkanti4441 Tanujkanti4441 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Screenshot 2025-02-16 120259

there is no border between the author's detail and last updated date section for small screen size can you fix that?

Also proposal in #612 says

It would enhance the user experience if the last updated date of the blog post were displayed somewhere on the page, allowing users to quickly see when it was last updated, rather than having to scroll down to the bottom of the page to check the update history.

and for small screen sizes we still have to scroll down to the bottom of the page, should we also add this date in header for small screens?

@amareshsm
Copy link
Member

I have a small suggestion regarding the design.

Current design Suggested design
image image

Can we maintain the same format as the other sections in the sidebar? For example, we have the section titles like "Contributors," "Tags," and "Share," followed by their respective content.

@Pixel998
Copy link
Contributor Author

Thanks for the reviews! I appreciate the feedback. I'm happy with the current design and will wait for Nicholas's input before making any changes.

@nzakas
Copy link
Member

nzakas commented Feb 17, 2025

and for small screen sizes we still have to scroll down to the bottom of the page, should we also add this date in header for small screens?

@Tanujkanti4441 no, I don't think that necessary.

@Pixel998 I like @amareshsm's design. He's on our website team so he's a good resource to work with.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Implementing
Development

Successfully merging this pull request may close these issues.

Suggestion: Add last updated date on blog posts
4 participants