Get post publishing date from within custom HTML block

Question

I am using a custom HTML block to create a customized title cover for a post on my WordPress site. I would like to get the current post publication date (rather than hard-coding it in and having to update manually). Is there a CSS selector or JavaScript function or I can use from within a custom HTML block to get the publication date?

0
Jason O 2 months 2022-08-10T14:14:19-05:00 0 Answers 0 views 0

Leave an answer

Browse
Browse