loading...

re: Generate an SEO-Friendly Sitemap for your Gatsby Site VIEW POST

FULL DISCUSSION
 

Hello!

Thank you for amazing post! Josh, pls, let me ask one question. In MDX-posts FrontMatter you set publish date. I mean string like this: publishedOn: 2020-03-09T09:30:00-0400

Please, tell me. How you write published date for MDX-posts? Is there any automatically solution? Or you write publish date for each posts manually? It's don't convenient.

 

Hi Zhandos!

I write them myself. When I'm ready to publish a post, I set that timestamp to the current time and deploy (I also have an isPublished boolean that controls whether it's seen in the list).

It's manual, but I'm also not sure how it could be more convenient =) no matter what I need to set the date somewhere, and I may as well keep it in the same place as the article. I don't have to do any other "work" to publish.

Code of Conduct Report abuse