mirror of
https://github.com/Einundzwanzig-Podcast/einundzwanzig.space.git
synced 2025-12-13 08:16:49 +00:00
Fix slugify for umlauts
This commit is contained in:
@@ -25,7 +25,7 @@ const stripHTML = str => {
|
||||
|
||||
// slug
|
||||
const slugify = str => str.toLowerCase()
|
||||
.replace('ä', 'ae').replace('ö', 'oe').replace('ü', 'ue')
|
||||
.replace(/ä/g, 'ae').replace(/ö/g, 'oe').replace(/ü/g, 'ue')
|
||||
.replace(/\s+/g, '-').replace(/[^\w\-]+/g, '')
|
||||
.replace(/\-\-+/g, '-').replace(/^-+/, '').replace(/-+$/, '')
|
||||
|
||||
|
||||
@@ -3,7 +3,9 @@ const { dirname, join, resolve } = require('path')
|
||||
|
||||
const redirects = [
|
||||
['/podcast/verschiedenes-special-zur-adoping-bitcoin-konferenz-in-el-salvador/', '/podcast/verschiedenes-special-zur-adopting-bitcoin-konferenz-in-el-salvador/'],
|
||||
['/podcast/der-wer-33-bitcoin-hat-mich-umgepolt/', '/podcast/der-weg-33-bitcoin-hat-mich-umgepolt/']
|
||||
['/podcast/der-wer-33-bitcoin-hat-mich-umgepolt/', '/podcast/der-weg-33-bitcoin-hat-mich-umgepolt/'],
|
||||
['/podcast/lesestunde-16-monetaeren-kolonialismus-mit-open-source-code-bekmpfen/', '/podcast/lesestunde-16-monetaeren-kolonialismus-mit-open-source-code-bekaempfen/'],
|
||||
['/podcast/news-93-die-legislatoren-muessen-verrckt-sein/', '/podcast/news-93-die-legislatoren-muessen-verrueckt-sein/']
|
||||
]
|
||||
|
||||
const dist = resolve(__dirname, '..', 'dist')
|
||||
|
||||
Reference in New Issue
Block a user