You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
539 B

---
location: [47.3639129,8.55627491017841]
---
# 2nd Test sheet for snippets
```dataviewjs
const header = '### 🗒 Notes'
const pages = dv.pages('"00.01 Admin/Calendars"')
const regex = new RegExp(`\n${header}\r?\n(.*?)(\n#+ |\n---|$)`, 's')
for (const page of pages) {
const file = app.vault.getAbstractFileByPath(page.file.path)
const contents = await app.vault.read(file)
const summary = contents.match(regex)
if (summary) {
dv.header(2, file.basename)
dv.paragraph(summary[1].trim())
}
}
```