Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
9380b6b5
Commit
9380b6b5
authored
May 19, 2017
by
Simon Chen
Committed by
GitHub
May 19, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #15151 from edx/schen/learner-490
LEARNER-490 Disable script auto-eval on lms
parents
a39dfbb2
9135e728
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
6 deletions
+20
-6
lms/static/lms/js/require-config.js
+20
-6
No files found.
lms/static/lms/js/require-config.js
View file @
9380b6b5
...
...
@@ -4,7 +4,7 @@
(
function
(
require
,
define
)
{
'use strict'
;
var
defineDependency
;
var
defineDependency
,
librarySetup
;
// We do not wish to bundle common libraries (that may also be used by non-RequireJS code on the page
// into the optimized files. Therefore load these libraries through script tags and explicitly define them.
...
...
@@ -31,15 +31,27 @@
console
.
error
(
'Expected library to be included on page, but not found on window object: '
+
name
);
}
};
librarySetup
=
function
()
{
// This is the function to setup all the vendor libraries
// Underscore.string no longer installs itself directly on '_'. For compatibility with existing
// code, add it to '_' with its previous name.
if
(
window
.
_
&&
window
.
s
)
{
window
.
_
.
str
=
window
.
s
;
}
window
.
$
.
ajaxSetup
({
contents
:
{
script
:
false
}
});
};
defineDependency
(
'jQuery'
,
'jquery'
);
defineDependency
(
'jQuery'
,
'jquery-migrate'
);
defineDependency
(
'_'
,
'underscore'
);
defineDependency
(
's'
,
'underscore.string'
);
// Underscore.string no longer installs itself directly on '_'. For compatibility with existing
// code, add it to '_' with its previous name.
if
(
window
.
_
&&
window
.
s
)
{
window
.
_
.
str
=
window
.
s
;
}
defineDependency
(
'gettext'
,
'gettext'
);
defineDependency
(
'Logger'
,
'logger'
);
defineDependency
(
'URI'
,
'URI'
);
...
...
@@ -52,6 +64,8 @@
// utility.js adds two functions to the window object, but does not return anything
defineDependency
(
'isExternal'
,
'utility'
,
true
);
librarySetup
();
}
require
.
config
({
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment