Extract data folder to root
This commit is contained in:
@ -56,6 +56,10 @@ Inside AstroWind template, you'll see the following folders and files:
|
||||
|
||||
```
|
||||
/
|
||||
├── data/
|
||||
| └── blog/
|
||||
| ├── post-slug-1.md
|
||||
| └── ...
|
||||
├── public/
|
||||
│ ├── robots.txt
|
||||
│ └── favicon.ico
|
||||
@ -64,10 +68,6 @@ Inside AstroWind template, you'll see the following folders and files:
|
||||
│ │ ├── images/
|
||||
| | └── styles/
|
||||
| | └── base.css
|
||||
│ ├── data/
|
||||
| | └── posts/
|
||||
| | ├── post-slug-1.md
|
||||
| | └── ...
|
||||
│ ├── components/
|
||||
│ │ ├── atoms/
|
||||
│ │ ├── blog/
|
||||
|
@ -27,7 +27,7 @@ const getNormalizedPost = async (post) => {
|
||||
};
|
||||
|
||||
const load = async function () {
|
||||
const posts = import.meta.glob('~/data/posts/**/*.md', {
|
||||
const posts = import.meta.glob('~/../data/blog/**/*.md', {
|
||||
eager: true,
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user