Remove camelcase dep, roll my own

This commit is contained in:
Will Boyd
2025-02-06 14:12:47 -05:00
parent df5731985d
commit 66798a044f
4 changed files with 152 additions and 109 deletions
+4
View File
@@ -1,5 +1,9 @@
import path from 'path';
export function camelCase(str) {
return str.replace(/-(.)/g, (match) => match[1].toUpperCase());
}
export function buildPostPath(outputDir, type, date, slug, config) {
// start with base output dir and post type
const pathSegments = [outputDir, type];