mirror of
https://github.com/ansible/awx.git
synced 2026-02-26 15:36:04 -03:30
Configure ace editor to not use blob worker
We don't rely on ace-editor using the blob worker and leaving it on causes CSP errors.
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
import React, { useEffect, useRef, useCallback } from 'react';
|
||||
import { oneOf, bool, number, string, func, oneOfType } from 'prop-types';
|
||||
import { config } from 'ace-builds';
|
||||
|
||||
import ReactAce from 'react-ace';
|
||||
import 'ace-builds/src-noconflict/mode-json';
|
||||
import 'ace-builds/src-noconflict/mode-javascript';
|
||||
@@ -11,6 +13,8 @@ import { t } from '@lingui/macro';
|
||||
import styled from 'styled-components';
|
||||
import debounce from '../../util/debounce';
|
||||
|
||||
config.set('loadWorkerFromBlob', false);
|
||||
|
||||
const LINE_HEIGHT = 24;
|
||||
const PADDING = 12;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user