mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-05-31 21:01:33 +02:00
Merge pull request #340 from sharelatex/bg-provide-default-requirejs-config
provide default requirejs config
This commit is contained in:
@@ -109,6 +109,19 @@ html(itemscope, itemtype='http://schema.org/Product')
|
||||
- if(typeof(suppressNavbar) == "undefined")
|
||||
include layout/navbar
|
||||
|
||||
script(type='text/javascript').
|
||||
// minimal requirejs configuration (can be extended/overridden)
|
||||
window.requirejs = {
|
||||
"paths" : {
|
||||
"moment": "libs/#{lib('moment')}"
|
||||
},
|
||||
"config":{
|
||||
"moment":{
|
||||
"noGlobal": true
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
block content
|
||||
div(ng-controller="AbTestController")
|
||||
- if(typeof(suppressFooter) == "undefined")
|
||||
@@ -120,20 +133,10 @@ html(itemscope, itemtype='http://schema.org/Product')
|
||||
span(ng-controller="ScribtexPopupController")
|
||||
include scribtex-modal
|
||||
|
||||
|
||||
- if(typeof(suppressFooter) == "undefined")
|
||||
- if(typeof(suppressDefaultJs) == "undefined")
|
||||
script(type='text/javascript').
|
||||
window.requirejs = {
|
||||
"urlArgs" : "fingerprint=#{fingerprint(jsPath + 'main.js')}-#{fingerprint(jsPath + 'libs.js')}",
|
||||
"paths" : {
|
||||
"moment": "libs/#{lib('moment')}"
|
||||
},
|
||||
"config":{
|
||||
"moment":{
|
||||
"noGlobal": true
|
||||
}
|
||||
}
|
||||
};
|
||||
// extend requirejs config
|
||||
window.requirejs.urlArgs = "fingerprint=#{fingerprint(jsPath + 'main.js')}-#{fingerprint(jsPath + 'libs.js')}"
|
||||
script(
|
||||
data-main=buildJsPath('main.js', {fingerprint:false}),
|
||||
baseurl=fullJsPath,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
extends ../layout
|
||||
|
||||
block content
|
||||
- locals.supressDefaultJs = true
|
||||
- locals.suppressDefaultJs = true
|
||||
script(data-main=jsPath+'main.js', src=jsPath+'libs/require.js', baseurl=jsPath)
|
||||
script(src=buildJsPath('libs/recurly.min.js', {fingerprint:false}))
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ block scripts
|
||||
window.couponCode = "#{couponCode}"
|
||||
|
||||
block content
|
||||
- locals.supressDefaultJs = true
|
||||
- locals.suppressDefaultJs = true
|
||||
script(data-main=jsPath+'main.js', src=jsPath+'libs/require.js', baseurl=jsPath)
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user