nuxt/content
### [`v2.0.1`](https://togithub.com/nuxt/content/releases/tag/2.0.1)
[Compare Source](https://togithub.com/nuxt/content/compare/2.0.0...2.0.1)
#### Important notes
Since [#1176](https://togithub.com/nuxt/content/issues/1176), we've modified the descending sorting behavior to be `-1` instead of `0` to stick with Mongo sort syntax.
```diff
- queryContent('/my-directory').sort({ createdAt: 0 })
+ queryContent('/my-directory').sort({ createdAt: -1 })
```
#### Features
We added `content:file:beforeParse` and `content:file:afterParse` hooks to manipulate the data before and after its transformation, you can read more in the [advanced section](https://content.nuxtjs.org/api/advanced) of the documentation. PR [#1160](https://togithub.com/nuxt/content/issues/1160) by [@farnabaz](https://togithub.com/farnabaz)
#### Fixes
- fix: ContentQuery `_path` not used properly ([#1141](https://togithub.com/nuxt/content/issues/1141)) by [@GerryWilko](https://togithub.com/GerryWilko) in [https://github.com/nuxt/content/pull/1143](https://togithub.com/nuxt/content/pull/1143)
- fix(frontmatter): issue with windows carriage return by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1161](https://togithub.com/nuxt/content/pull/1161)
- fix: typo that->than, highlight span to improve comprehension by [@TheJoeSchr](https://togithub.com/TheJoeSchr) in [https://github.com/nuxt/content/pull/1163](https://togithub.com/nuxt/content/pull/1163)
- fix(ContentQuery): generate cache key based on props by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1174](https://togithub.com/nuxt/content/pull/1174)
- fix(sort): use `-1` for descending same as mongo syntax by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1176](https://togithub.com/nuxt/content/pull/1176)
- fix(navigation): do not nest home page by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1179](https://togithub.com/nuxt/content/pull/1179)
- fix(sort): convert Date to ISO string by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1175](https://togithub.com/nuxt/content/pull/1175)
- fix(types): `_title` rename to `title` by [@cawa-93](https://togithub.com/cawa-93) in [https://github.com/nuxt/content/pull/1181](https://togithub.com/nuxt/content/pull/1181)
- fix(query): escape special chars in path by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1185](https://togithub.com/nuxt/content/pull/1185)
#### Docs
- docs: Update 1.query-content.md by [@jhull](https://togithub.com/jhull) in [https://github.com/nuxt/content/pull/1138](https://togithub.com/nuxt/content/pull/1138)
- docs: correct spelling of ContentDoc by [@nobkd](https://togithub.com/nobkd) in [https://github.com/nuxt/content/pull/1144](https://togithub.com/nuxt/content/pull/1144)
- docs: fix template name by [@manniL](https://togithub.com/manniL) in [https://github.com/nuxt/content/pull/1147](https://togithub.com/nuxt/content/pull/1147)
- docs: correctly link to catch-all documentation by [@loilo](https://togithub.com/loilo) in [https://github.com/nuxt/content/pull/1148](https://togithub.com/nuxt/content/pull/1148)
- docs: content comment is now link to option docs by [@ravenberg](https://togithub.com/ravenberg) in [https://github.com/nuxt/content/pull/1150](https://togithub.com/nuxt/content/pull/1150)
- docs: typo by [@seanghay](https://togithub.com/seanghay) in [https://github.com/nuxt/content/pull/1158](https://togithub.com/nuxt/content/pull/1158)
- docs: added information on sitemap generation by [@heychazza](https://togithub.com/heychazza) in [https://github.com/nuxt/content/pull/1145](https://togithub.com/nuxt/content/pull/1145)
- docs: typo Rendering Doc by [@king-11](https://togithub.com/king-11) in [https://github.com/nuxt/content/pull/1162](https://togithub.com/nuxt/content/pull/1162)
- docs: add `--shamefully-hoist` argument to pnpm install by [@Julien-R44](https://togithub.com/Julien-R44) in [https://github.com/nuxt/content/pull/1159](https://togithub.com/nuxt/content/pull/1159)
- docs: fix querying example route is not defined by [@Jclong98](https://togithub.com/Jclong98) in [https://github.com/nuxt/content/pull/1166](https://togithub.com/nuxt/content/pull/1166)
- docs: correct path of ContentRenderer source code by [@sudhakar-s](https://togithub.com/sudhakar-s) in [https://github.com/nuxt/content/pull/1165](https://togithub.com/nuxt/content/pull/1165)
- docs(redirects): remove configuration redirect by [@clemcode](https://togithub.com/clemcode) in [https://github.com/nuxt/content/pull/1183](https://togithub.com/nuxt/content/pull/1183)
- docs:fixing navigation comments re: default value by [@MichaelJolley](https://togithub.com/MichaelJolley) in [https://github.com/nuxt/content/pull/1182](https://togithub.com/nuxt/content/pull/1182)
#### Misc
- chore(deps): update devdependency lint-staged to ^12.4.3 by [@renovate](https://togithub.com/renovate) in [https://github.com/nuxt/content/pull/1173](https://togithub.com/nuxt/content/pull/1173)
- chore(deps): update all non-major dependencies by [@renovate](https://togithub.com/renovate) in [https://github.com/nuxt/content/pull/1134](https://togithub.com/nuxt/content/pull/1134)
- chore(deps): lock file maintenance by [@renovate](https://togithub.com/renovate) in [https://github.com/nuxt/content/pull/1172](https://togithub.com/nuxt/content/pull/1172)
- chore(deps): update devdependency lint-staged to ^12.5.0 by [@renovate](https://togithub.com/renovate) in [https://github.com/nuxt/content/pull/1186](https://togithub.com/nuxt/content/pull/1186)
#### New Contributors
- [@jhull](https://togithub.com/jhull) made their first contribution in [https://github.com/nuxt/content/pull/1138](https://togithub.com/nuxt/content/pull/1138)
- [@nobkd](https://togithub.com/nobkd) made their first contribution in [https://github.com/nuxt/content/pull/1144](https://togithub.com/nuxt/content/pull/1144)
- [@GerryWilko](https://togithub.com/GerryWilko) made their first contribution in [https://github.com/nuxt/content/pull/1143](https://togithub.com/nuxt/content/pull/1143)
- [@loilo](https://togithub.com/loilo) made their first contribution in [https://github.com/nuxt/content/pull/1148](https://togithub.com/nuxt/content/pull/1148)
- [@ravenberg](https://togithub.com/ravenberg) made their first contribution in [https://github.com/nuxt/content/pull/1150](https://togithub.com/nuxt/content/pull/1150)
- [@seanghay](https://togithub.com/seanghay) made their first contribution in [https://github.com/nuxt/content/pull/1158](https://togithub.com/nuxt/content/pull/1158)
- [@king-11](https://togithub.com/king-11) made their first contribution in [https://github.com/nuxt/content/pull/1162](https://togithub.com/nuxt/content/pull/1162)
- [@Julien-R44](https://togithub.com/Julien-R44) made their first contribution in [https://github.com/nuxt/content/pull/1159](https://togithub.com/nuxt/content/pull/1159)
- [@TheJoeSchr](https://togithub.com/TheJoeSchr) made their first contribution in [https://github.com/nuxt/content/pull/1163](https://togithub.com/nuxt/content/pull/1163)
- [@Jclong98](https://togithub.com/Jclong98) made their first contribution in [https://github.com/nuxt/content/pull/1166](https://togithub.com/nuxt/content/pull/1166)
- [@sudhakar-s](https://togithub.com/sudhakar-s) made their first contribution in [https://github.com/nuxt/content/pull/1165](https://togithub.com/nuxt/content/pull/1165)
- [@cawa-93](https://togithub.com/cawa-93) made their first contribution in [https://github.com/nuxt/content/pull/1181](https://togithub.com/nuxt/content/pull/1181)
- [@MichaelJolley](https://togithub.com/MichaelJolley) made their first contribution in [https://github.com/nuxt/content/pull/1182](https://togithub.com/nuxt/content/pull/1182)
- [@heychazza](https://togithub.com/heychazza) made their first contribution in [https://github.com/nuxt/content/pull/1145](https://togithub.com/nuxt/content/pull/1145)
**Full Changelog**: https://github.com/nuxt/content/compare/2.0.0...2.0.1
### [`v2.0.0`](https://togithub.com/nuxt/content/releases/tag/2.0.0)
[Compare Source](https://togithub.com/nuxt/content/compare/@nuxt/content@1.15.1...2.0.0)
### [@nuxt/content](https://togithub.com/nuxt/content) v2
- [📖 Read the documentation](https://content.nuxtjs.org)
- [👾 Playground](https://stackblitz.com/github/nuxt/content/tree/main/examples/essentials/hello-world?file=app.vue)
- [✨ Intro video](https://www.youtube.com/watch?v=o9e12WbKrd8)
After months of work we are finally officially releasing [@nuxt/content](https://togithub.com/nuxt/content) v2.
This update main objective was to be fully compatible with Nuxt 3.
It also comes with new features and possibilities to discover:
- ``, ``, and other powerful new components
- A Markdown syntax made for Vue components ([**MDC**](https://content.nuxtjs.org/guide/writing/mdc))
- Navigation generation
- Code highlighting with [**Shiki**](https://shiki.matsu.io)
In addition to all the current features from [@nuxt/content](https://togithub.com/nuxt/content) v1:
- Powerful query builder (MongoDB like)
- Blazing fast hot module replacement in development
- Table of contents generation
- Queries into CSV, YAML and JSON(5) content
- Extend with hooks and content plugins
- [...and more](https://content.nuxtjs.org)
## ❤️ Thanks
This could not have been possible without the hard work from the [@nuxt](https://togithub.com/nuxt) community!
A special thanks to [@farnabaz](https://togithub.com/farnabaz), [@Atinux](https://togithub.com/Atinux), [@pi0](https://togithub.com/pi0), [@danielroe](https://togithub.com/danielroe), [@clemcode](https://togithub.com/clemcode) who all closely contributed to this release.
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
[ ] If you want to rebase/retry this PR, click this checkbox.
This PR has been generated by Mend Renovate. View repository job log here.
This PR contains the following updates:
^1.15.1
->^2.0.0
Release Notes
nuxt/content
### [`v2.0.1`](https://togithub.com/nuxt/content/releases/tag/2.0.1) [Compare Source](https://togithub.com/nuxt/content/compare/2.0.0...2.0.1) #### Important notes Since [#1176](https://togithub.com/nuxt/content/issues/1176), we've modified the descending sorting behavior to be `-1` instead of `0` to stick with Mongo sort syntax. ```diff - queryContent('/my-directory').sort({ createdAt: 0 }) + queryContent('/my-directory').sort({ createdAt: -1 }) ``` #### Features We added `content:file:beforeParse` and `content:file:afterParse` hooks to manipulate the data before and after its transformation, you can read more in the [advanced section](https://content.nuxtjs.org/api/advanced) of the documentation. PR [#1160](https://togithub.com/nuxt/content/issues/1160) by [@farnabaz](https://togithub.com/farnabaz) #### Fixes - fix: ContentQuery `_path` not used properly ([#1141](https://togithub.com/nuxt/content/issues/1141)) by [@GerryWilko](https://togithub.com/GerryWilko) in [https://github.com/nuxt/content/pull/1143](https://togithub.com/nuxt/content/pull/1143) - fix(frontmatter): issue with windows carriage return by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1161](https://togithub.com/nuxt/content/pull/1161) - fix: typo that->than, highlight span to improve comprehension by [@TheJoeSchr](https://togithub.com/TheJoeSchr) in [https://github.com/nuxt/content/pull/1163](https://togithub.com/nuxt/content/pull/1163) - fix(ContentQuery): generate cache key based on props by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1174](https://togithub.com/nuxt/content/pull/1174) - fix(sort): use `-1` for descending same as mongo syntax by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1176](https://togithub.com/nuxt/content/pull/1176) - fix(navigation): do not nest home page by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1179](https://togithub.com/nuxt/content/pull/1179) - fix(sort): convert Date to ISO string by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1175](https://togithub.com/nuxt/content/pull/1175) - fix(types): `_title` rename to `title` by [@cawa-93](https://togithub.com/cawa-93) in [https://github.com/nuxt/content/pull/1181](https://togithub.com/nuxt/content/pull/1181) - fix(query): escape special chars in path by [@farnabaz](https://togithub.com/farnabaz) in [https://github.com/nuxt/content/pull/1185](https://togithub.com/nuxt/content/pull/1185) #### Docs - docs: Update 1.query-content.md by [@jhull](https://togithub.com/jhull) in [https://github.com/nuxt/content/pull/1138](https://togithub.com/nuxt/content/pull/1138) - docs: correct spelling of ContentDoc by [@nobkd](https://togithub.com/nobkd) in [https://github.com/nuxt/content/pull/1144](https://togithub.com/nuxt/content/pull/1144) - docs: fix template name by [@manniL](https://togithub.com/manniL) in [https://github.com/nuxt/content/pull/1147](https://togithub.com/nuxt/content/pull/1147) - docs: correctly link to catch-all documentation by [@loilo](https://togithub.com/loilo) in [https://github.com/nuxt/content/pull/1148](https://togithub.com/nuxt/content/pull/1148) - docs: content comment is now link to option docs by [@ravenberg](https://togithub.com/ravenberg) in [https://github.com/nuxt/content/pull/1150](https://togithub.com/nuxt/content/pull/1150) - docs: typo by [@seanghay](https://togithub.com/seanghay) in [https://github.com/nuxt/content/pull/1158](https://togithub.com/nuxt/content/pull/1158) - docs: added information on sitemap generation by [@heychazza](https://togithub.com/heychazza) in [https://github.com/nuxt/content/pull/1145](https://togithub.com/nuxt/content/pull/1145) - docs: typo Rendering Doc by [@king-11](https://togithub.com/king-11) in [https://github.com/nuxt/content/pull/1162](https://togithub.com/nuxt/content/pull/1162) - docs: add `--shamefully-hoist` argument to pnpm install by [@Julien-R44](https://togithub.com/Julien-R44) in [https://github.com/nuxt/content/pull/1159](https://togithub.com/nuxt/content/pull/1159) - docs: fix querying example route is not defined by [@Jclong98](https://togithub.com/Jclong98) in [https://github.com/nuxt/content/pull/1166](https://togithub.com/nuxt/content/pull/1166) - docs: correct path of ContentRenderer source code by [@sudhakar-s](https://togithub.com/sudhakar-s) in [https://github.com/nuxt/content/pull/1165](https://togithub.com/nuxt/content/pull/1165) - docs(redirects): remove configuration redirect by [@clemcode](https://togithub.com/clemcode) in [https://github.com/nuxt/content/pull/1183](https://togithub.com/nuxt/content/pull/1183) - docs:fixing navigation comments re: default value by [@MichaelJolley](https://togithub.com/MichaelJolley) in [https://github.com/nuxt/content/pull/1182](https://togithub.com/nuxt/content/pull/1182) #### Misc - chore(deps): update devdependency lint-staged to ^12.4.3 by [@renovate](https://togithub.com/renovate) in [https://github.com/nuxt/content/pull/1173](https://togithub.com/nuxt/content/pull/1173) - chore(deps): update all non-major dependencies by [@renovate](https://togithub.com/renovate) in [https://github.com/nuxt/content/pull/1134](https://togithub.com/nuxt/content/pull/1134) - chore(deps): lock file maintenance by [@renovate](https://togithub.com/renovate) in [https://github.com/nuxt/content/pull/1172](https://togithub.com/nuxt/content/pull/1172) - chore(deps): update devdependency lint-staged to ^12.5.0 by [@renovate](https://togithub.com/renovate) in [https://github.com/nuxt/content/pull/1186](https://togithub.com/nuxt/content/pull/1186) #### New Contributors - [@jhull](https://togithub.com/jhull) made their first contribution in [https://github.com/nuxt/content/pull/1138](https://togithub.com/nuxt/content/pull/1138) - [@nobkd](https://togithub.com/nobkd) made their first contribution in [https://github.com/nuxt/content/pull/1144](https://togithub.com/nuxt/content/pull/1144) - [@GerryWilko](https://togithub.com/GerryWilko) made their first contribution in [https://github.com/nuxt/content/pull/1143](https://togithub.com/nuxt/content/pull/1143) - [@loilo](https://togithub.com/loilo) made their first contribution in [https://github.com/nuxt/content/pull/1148](https://togithub.com/nuxt/content/pull/1148) - [@ravenberg](https://togithub.com/ravenberg) made their first contribution in [https://github.com/nuxt/content/pull/1150](https://togithub.com/nuxt/content/pull/1150) - [@seanghay](https://togithub.com/seanghay) made their first contribution in [https://github.com/nuxt/content/pull/1158](https://togithub.com/nuxt/content/pull/1158) - [@king-11](https://togithub.com/king-11) made their first contribution in [https://github.com/nuxt/content/pull/1162](https://togithub.com/nuxt/content/pull/1162) - [@Julien-R44](https://togithub.com/Julien-R44) made their first contribution in [https://github.com/nuxt/content/pull/1159](https://togithub.com/nuxt/content/pull/1159) - [@TheJoeSchr](https://togithub.com/TheJoeSchr) made their first contribution in [https://github.com/nuxt/content/pull/1163](https://togithub.com/nuxt/content/pull/1163) - [@Jclong98](https://togithub.com/Jclong98) made their first contribution in [https://github.com/nuxt/content/pull/1166](https://togithub.com/nuxt/content/pull/1166) - [@sudhakar-s](https://togithub.com/sudhakar-s) made their first contribution in [https://github.com/nuxt/content/pull/1165](https://togithub.com/nuxt/content/pull/1165) - [@cawa-93](https://togithub.com/cawa-93) made their first contribution in [https://github.com/nuxt/content/pull/1181](https://togithub.com/nuxt/content/pull/1181) - [@MichaelJolley](https://togithub.com/MichaelJolley) made their first contribution in [https://github.com/nuxt/content/pull/1182](https://togithub.com/nuxt/content/pull/1182) - [@heychazza](https://togithub.com/heychazza) made their first contribution in [https://github.com/nuxt/content/pull/1145](https://togithub.com/nuxt/content/pull/1145) **Full Changelog**: https://github.com/nuxt/content/compare/2.0.0...2.0.1 ### [`v2.0.0`](https://togithub.com/nuxt/content/releases/tag/2.0.0) [Compare Source](https://togithub.com/nuxt/content/compare/@nuxt/content@1.15.1...2.0.0) ### [@nuxt/content](https://togithub.com/nuxt/content) v2 - [📖 Read the documentation](https://content.nuxtjs.org) - [👾 Playground](https://stackblitz.com/github/nuxt/content/tree/main/examples/essentials/hello-world?file=app.vue) - [✨ Intro video](https://www.youtube.com/watch?v=o9e12WbKrd8) After months of work we are finally officially releasing [@nuxt/content](https://togithub.com/nuxt/content) v2. This update main objective was to be fully compatible with Nuxt 3. It also comes with new features and possibilities to discover: - `Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.