0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-01-01 13:02:43 +00:00

Probably terrible solution

This commit is contained in:
G.Ambatte
2024-06-30 23:30:40 +12:00
parent 47b78510df
commit 5c2f603860
3 changed files with 15275 additions and 15266 deletions

View File

@@ -15,8 +15,17 @@ const Frame = require('react-frame-component').default;
const dedent = require('dedent-tabs').default;
const { printCurrentBrew } = require('../../../shared/helpers.js');
const DOMPurify = require('dompurify');
const purifyConfig = { FORCE_BODY: true, SANITIZE_DOM: false, ADD_ATTR: ['target'] };
import DOMPurify from 'dompurify';
const purifyConfig = {
ADD_ATTR : ['id', 'target'],
IGNORE_BASIC_CUSTOM_ELEMENT : true, // ignore the custom-element naming specification
CUSTOM_ELEMENT_HANDLING : {
tagNameCheck : ()=>{ return true; }, // all elements are allowed
attributeNameCheck : null, // default / standard attribute allow-list is used
allowCustomizedBuiltInElements : false, // no customized built-ins allowed
},
};
const Themes = require('themes/themes.json');