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
68f6aa8c
Commit
68f6aa8c
authored
Oct 21, 2013
by
David Baumgold
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1404 from edx/db/requirejs-configure-mathjax
Configure MathJax using require.js
parents
fb62f0c5
97941530
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
45 additions
and
6 deletions
+45
-6
cms/static/coffee/spec/main.coffee
+14
-2
cms/static/coffee/spec/main_squire.coffee
+14
-2
cms/templates/base.html
+17
-2
No files found.
cms/static/coffee/spec/main.coffee
View file @
68f6aa8c
...
...
@@ -35,7 +35,7 @@ requirejs.config({
"draggabilly"
:
"xmodule_js/common_static/js/vendor/draggabilly.pkgd"
,
"domReady"
:
"xmodule_js/common_static/js/vendor/domReady"
,
"mathjax"
:
"//edx-static.s3.amazonaws.com/mathjax-MathJax-727332c/MathJax.js?config=TeX-MML-AM_HTMLorMML-full"
,
"mathjax"
:
"//edx-static.s3.amazonaws.com/mathjax-MathJax-727332c/MathJax.js?config=TeX-MML-AM_HTMLorMML-full
&delayStartupUntil=configured
"
,
"youtube"
:
"//www.youtube.com/player_api?noext"
,
"tender"
:
"//edxedge.tenderapp.com/tender_widget"
...
...
@@ -116,7 +116,19 @@ requirejs.config({
exports
:
"tinymce"
},
"mathjax"
:
{
exports
:
"MathJax"
exports
:
"MathJax"
,
init
:
->
MathJax
.
Hub
.
Config
tex2jax
:
inlineMath
:
[
[
"
\\
("
,
"
\\
)"
],
[
'[mathjaxinline]'
,
'[/mathjaxinline]'
]
]
displayMath
:
[
[
"
\\
["
,
"
\\
]"
],
[
'[mathjax]'
,
'[/mathjax]'
]
]
MathJax
.
Hub
.
Configured
()
},
"xmodule"
:
{
exports
:
"XModule"
...
...
cms/static/coffee/spec/main_squire.coffee
View file @
68f6aa8c
...
...
@@ -35,7 +35,7 @@ requirejs.config({
"draggabilly"
:
"xmodule_js/common_static/js/vendor/draggabilly.pkgd"
,
"domReady"
:
"xmodule_js/common_static/js/vendor/domReady"
,
"mathjax"
:
"//edx-static.s3.amazonaws.com/mathjax-MathJax-727332c/MathJax.js?config=TeX-MML-AM_HTMLorMML-full"
,
"mathjax"
:
"//edx-static.s3.amazonaws.com/mathjax-MathJax-727332c/MathJax.js?config=TeX-MML-AM_HTMLorMML-full
&delayStartupUntil=configured
"
,
"youtube"
:
"//www.youtube.com/player_api?noext"
,
"tender"
:
"//edxedge.tenderapp.com/tender_widget.js"
...
...
@@ -116,7 +116,19 @@ requirejs.config({
exports
:
"tinymce"
},
"mathjax"
:
{
exports
:
"MathJax"
exports
:
"MathJax"
,
init
:
->
MathJax
.
Hub
.
Config
tex2jax
:
inlineMath
:
[
[
"
\\
("
,
"
\\
)"
],
[
'[mathjaxinline]'
,
'[/mathjaxinline]'
]
]
displayMath
:
[
[
"
\\
["
,
"
\\
]"
],
[
'[mathjax]'
,
'[/mathjax]'
]
]
MathJax
.
Hub
.
Configured
();
},
"xmodule"
:
{
exports
:
"XModule"
...
...
cms/templates/base.html
View file @
68f6aa8c
...
...
@@ -71,7 +71,7 @@ var require = {
// externally hosted files
"tender"
:
"//edxedge.tenderapp.com/tender_widget"
,
"mathjax"
:
"//edx-static.s3.amazonaws.com/mathjax-MathJax-727332c/MathJax.js?config=TeX-MML-AM_HTMLorMML-full"
,
"mathjax"
:
"//edx-static.s3.amazonaws.com/mathjax-MathJax-727332c/MathJax.js?config=TeX-MML-AM_HTMLorMML-full
&delayStartupUntil=configured
"
,
// youtube URL does not end in ".js". We add "?noext" to the path so
// that require.js adds the ".js" to the query component of the URL,
// and leaves the path component intact.
...
...
@@ -159,7 +159,22 @@ var require = {
exports
:
"tinymce"
},
"mathjax"
:
{
exports
:
"MathJax"
exports
:
"MathJax"
,
init
:
function
()
{
MathJax
.
Hub
.
Config
({
tex2jax
:
{
inlineMath
:
[
[
"
\\
("
,
"
\\
)"
],
[
'[mathjaxinline]'
,
'[/mathjaxinline]'
]
],
displayMath
:
[
[
"
\\
["
,
"
\\
]"
],
[
'[mathjax]'
,
'[/mathjax]'
]
]
}
});
MathJax
.
Hub
.
Configured
();
}
},
"xblock/core"
:
{
exports
:
"XBlock"
,
...
...
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