Fix text encoding issues in NKJV files by removing UTF-8 BOM in readMarkdownFile
This commit is contained in:
@@ -166,8 +166,9 @@ function App() {
|
||||
|
||||
// Helper function to format book names for display
|
||||
const formatBookName = (bookName: string): string => {
|
||||
// Remove leading numbers and underscores, replace underscores with spaces
|
||||
return bookName.replace(/^\d+_/, '').replace(/_/g, ' ');
|
||||
// Handle both formats: numbered (01_Genesis) and regular (Genesis)
|
||||
const cleanName = bookName.replace(/^\d+_/, ''); // Remove leading number and underscore
|
||||
return cleanName.replace(/_/g, ' '); // Replace underscores with spaces
|
||||
};
|
||||
|
||||
// Helper function to convert display name back to file name
|
||||
|
||||
Reference in New Issue
Block a user