0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2025-12-26 20:22:42 +00:00

Load editorThemes in SnippetBar.jsx

This commit is contained in:
G.Ambatte
2023-09-07 17:33:36 +12:00
parent e16110da6a
commit e909bc8f35
3 changed files with 8 additions and 9 deletions

View File

@@ -17,8 +17,6 @@ const asyncHandler = require('express-async-handler');
const { DEFAULT_BREW } = require('./brewDefaults.js');
const codeMirrorThemes = require('../themes/codeMirror/editorThemes.json');
const splitTextStyleAndMetadata = (brew)=>{
brew.text = brew.text.replaceAll('\r\n', '\n');
if(brew.text.startsWith('```metadata')) {
@@ -419,10 +417,9 @@ const templateFn = require('./../client/template.js');
const renderPage = async (req, res)=>{
// Create configuration object
const configuration = {
local : isLocalEnvironment,
publicUrl : config.get('publicUrl') ?? '',
environment : nodeEnv,
codeMirrorThemes : codeMirrorThemes
local : isLocalEnvironment,
publicUrl : config.get('publicUrl') ?? '',
environment : nodeEnv
};
const props = {
version : require('./../package.json').version,