Skip to content

wdssmq/blog-astro

Repository files navigation

Blog Astro

A static blog based on Astro;

It is planned to imitate a grid theme as an exercise: " Getgrid/grid theme simple: a beautiful grid theme Simple 」;

use

wdssmq/blog-astro: https://github.com/wdssmq/blog-astro

1. Use the above warehouse as a template to create a new warehouse;

2. Clone to local;

3. Installation dependency and operation, pnpm is recommended;

 pnpm install # Commissioning development npm run dev # structure npm run build

4. Various descriptions:

  1. Although it can be used as a blog, it does not have the "theme" standard in the sense of a general blog. I still try to put the file in src/theme-simple Directory, src/pages Because of Astro's limitation, it can only be placed outside;
  2. src/theme-simple/config.ts It is used for preset and consolidated configuration. For customization src/consts.ts Medium;
  3. astro.config.mjs There are site The field is used to set the domain name; "It seems that config.site.url It is also repeated "
  4. The article content path is src/content , you can symbolic link or shortcut to other places to facilitate management;
  5. There is a built-in "About" page, the path src/content/pages/about.md It should not be deleted, and other file names will not be resolved to new pages
  6. Articles are stored in src/content/blog In the path, you can clear it and then create a new one;

5. Update:

  1. Clone or download wdssmq/blog-astro Warehouse;
  2. Use Beyond Compare or other tools to compare differences;
  3. Overwrite the file as follows:
    • src/content/config.ts 「 2023-08-26: The configuration in this file will be changed from src/theme-simple/config.ts Import
    • src/theme-simple All documents within; 「 2023-08-26: Copy the original custom configuration to the new version src/consts.ts Inside
    • src/pages All documents within;
    • package.json
  4. Additional comparisons public astro.config.mjs src/consts.ts Content;
  5. Reinstall dependencies and then debug and run them;

recommend: Tip. Additional usage or update instructions · Issue # 4 · wdssmq/blog astro "Exclusion rules for Beyond Compare are provided"

file

Getting Started Guide 🚀 Astro Documentation:

https://docs.astro.build/zh-cn/getting-started/

astro/examples/blog at latest · withastro/astro · GitHub:

https://github.com/withastro/astro/tree/latest/examples/blog?on=github#astro -starter-kit-blog

Related recommendations

Austin2035/astro air blog: A minimalist, beautiful, responsive blogging program written in Astro

https://github.com/austin2035/astro-air-blog

Feeding support

Love Power Generation: https://afdian.net/a/wdssmq

Bili Bili: https://space.bilibili.com/44744006/video [Coin insertion or charging] Large membership card coupon collection - bilibili

RSS subscription: https://feed.wdssmq.com/ "Speaking" RSS is an attitude!!

Follow me on more platforms: https://www.wdssmq.com/guestbook.html# Other haunting sites and information

More "small codes": https://cn.bing.com/search?q= Small code+ice floating water