Skip to content

How to use BlogHighlightedPosts #476

Closed Answered by Harold-Anderson
Harold-Anderson asked this question in Q&A
Discussion options

You must be logged in to vote

BlogHighlightedPosts works suboptimally and is not documented. In order to get it to work, you have to create an array in your index.astro page called

const postIds[] = {['foo.md','bar.md']}

Then BlogHighlightedPosts will display foo.md first, then bar.md.

Please note that this is not how the list of blog articles in the menu works in Astrowind. The list of blog articles in the menu displays the articles in reverse chronological order. This is sometimes not what is wanted. In order to fix this, I changed the load function to order by id, which Astrowind defines as the name of the blog markdown file. You can see this on my Github repository here. Please note that you then need to rename yo…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by Harold-Anderson
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant