mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2025-12-27 02:52:43 +00:00
Probably terrible solution
This commit is contained in:
@@ -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');
|
||||
|
||||
|
||||
30526
package-lock.json
generated
30526
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -93,7 +93,7 @@
|
||||
"cookie-parser": "^1.4.6",
|
||||
"create-react-class": "^15.7.0",
|
||||
"dedent-tabs": "^0.10.3",
|
||||
"dompurify": "^3.1.5",
|
||||
"dompurify": "git+https://github.com/G-Ambatte/DOMPurify.git#AddConfigOption-IGNORE_BASIC_CUSTOM_ELEMENT",
|
||||
"expr-eval": "^2.0.2",
|
||||
"express": "^4.19.2",
|
||||
"express-async-handler": "^1.2.0",
|
||||
|
||||
Reference in New Issue
Block a user