Skip to content

Commit

Permalink
Remove % from file names for slugs
Browse files Browse the repository at this point in the history
  • Loading branch information
puf committed Jul 26, 2024
1 parent 651806c commit 4eaddf2
Show file tree
Hide file tree
Showing 8 changed files with 2 additions and 58 deletions.
11 changes: 0 additions & 11 deletions books copy/Chip War - Chris Miller.md

This file was deleted.

11 changes: 0 additions & 11 deletions books copy/The Lost Cause - Cory Doctorrow.md

This file was deleted.

11 changes: 0 additions & 11 deletions books copy/The Ride of a Lifetime - Bob Iger.md

This file was deleted.

11 changes: 0 additions & 11 deletions books copy/The Rule of Threes - Jeffery Deaver.md

This file was deleted.

12 changes: 0 additions & 12 deletions books copy/To Be Taught, If Fortunate - Becky Chambers.md

This file was deleted.

1 change: 0 additions & 1 deletion books copy/_readme.md

This file was deleted.

2 changes: 1 addition & 1 deletion src/components/Notes.astro
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export function getSlugForNote(note) {
.replace(notesPath, "") // remove local path
.replace(/\.md$/, "") // remove .md extension
.toLowerCase().replace(/\s/g, '-') // replace spaces with -
.split("").filter(c => "()".indexOf(c) == -1).join("") // remove some chars
.split("").filter(c => "()%".indexOf(c) == -1).join("") // remove some chars
.replace(/_readme$/, "") // treat _readme.md like an index.html
;
}
Expand Down
1 change: 1 addition & 0 deletions tools/src/env.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/// <reference types="astro/client" />

0 comments on commit 4eaddf2

Please sign in to comment.