Skip to content

v7.2.0

Latest

Choose a tag to compare

@satnaing satnaing released this 15 Nov 08:54
· 1 commit to main since this release

Highlights

Custom slots for your own code. src/custom/ has three empty components the theme always renders (#728):

  • Head.astro: end of <head> on every page (analytics, site verification, extra <meta>, <link> or stylesheets)
  • BodyEnd.astro: end of <body> on every page (scripts and widgets)
  • PostEnd.astro: post pages, after the share links (comments, a newsletter form, an author bio). It gets the post, so you can skip some posts.

They render nothing until you add something, so your site's output doesn't change.

Upgrading from v7.1

  • Copy the src/custom/ folder and the theme's src/layouts/Layout.astro and src/pages/posts/[...slug]/index.astro. If you've edited those two files, add the imports and the <CustomHead />, <CustomBodyEnd /> and <PostEnd /> lines from this release by hand.
  • src/custom/ is yours from now on. AstroPaper won't change, move or rename these files in later releases. So if you've added code to theme files (analytics in Layout.astro, comments in the post page), moving it to these slots makes the next update easier.
  • The LaTeX guide now imports KaTeX's CSS in src/custom/Head.astro instead of Layout.astro.

Heads-ups

  • @astrojs/mdx 8 (#724). Nothing changes if your astro.config.ts calls mdx() with no options, like the theme's. If you pass remarkPlugins, rehypePlugins or extendMarkdownConfig: false to mdx(), remove them, or .mdx posts lose callouts, table wrappers and the inline TOC.

Dependencies

  • Astro 7.4.8, Tailwind CSS 4.3.5 and other minor and patch updates (#723, #726, #727)

What's Changed

  • build(deps): bump the minor-and-patch group with 2 updates by @dependabot[bot] in #723
  • build(deps): bump @astrojs/mdx from 7.0.8 to 8.1.2 by @dependabot[bot] in #724
  • build(deps): bump fast-xml-parser from 5.11.2 to 5.12.0 in the security group across 1 directory by @dependabot[bot] in #726
  • feat: add custom slots for head, body end and post end by @satnaing in #728
  • build(deps): bump the minor-and-patch group with 6 updates by @dependabot[bot] in #727

Full Changelog: v7.1.0...v7.2.0