Use dedicated shareon file
This means the main JS file is smaller
This commit is contained in:
parent
ce63774cbd
commit
ef5b5b7540
3 changed files with 3 additions and 3 deletions
|
@ -42,6 +42,8 @@
|
||||||
|
|
||||||
{{ partial "script_async.html" "js/app.js" }}
|
{{ partial "script_async.html" "js/app.js" }}
|
||||||
|
|
||||||
|
{{ partial "script_async.html" "js/shareon.js" }}
|
||||||
|
|
||||||
{{ block "scripts_extra" . }}{{ end }}
|
{{ block "scripts_extra" . }}{{ end }}
|
||||||
|
|
||||||
{{ if not .Site.IsServer }}
|
{{ if not .Site.IsServer }}
|
||||||
|
|
|
@ -20,6 +20,7 @@ cp $BASEDIR/node_modules/shareon/dist/shareon.min.css $STATIC_BUILD/css/shareon.
|
||||||
|
|
||||||
cp -r $STATIC_SRC/js/ $STATIC_BUILD/js/
|
cp -r $STATIC_SRC/js/ $STATIC_BUILD/js/
|
||||||
cp $BASEDIR/node_modules/jquery/dist/jquery.min.js $STATIC_BUILD/js/jquery.min.js
|
cp $BASEDIR/node_modules/jquery/dist/jquery.min.js $STATIC_BUILD/js/jquery.min.js
|
||||||
|
cp $BASEDIR/node_modules/shareon/dist/shareon.min.js $STATIC_BUILD/js/shareon.js
|
||||||
cp $BASEDIR/node_modules/lightgallery/dist/js/lightgallery-all.min.js $STATIC_BUILD/js/lightgallery.min.js
|
cp $BASEDIR/node_modules/lightgallery/dist/js/lightgallery-all.min.js $STATIC_BUILD/js/lightgallery.min.js
|
||||||
cp $BASEDIR/node_modules/bootstrap/dist/js/bootstrap.bundle.min.js $STATIC_BUILD/js/bootstrap.min.js
|
cp $BASEDIR/node_modules/bootstrap/dist/js/bootstrap.bundle.min.js $STATIC_BUILD/js/bootstrap.min.js
|
||||||
cp $BASEDIR/node_modules/elevator.js/demo/music/*.mp3 $STATIC_BUILD/audio/
|
cp $BASEDIR/node_modules/elevator.js/demo/music/*.mp3 $STATIC_BUILD/audio/
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
const Elevator = require('elevator.js');
|
const Elevator = require('elevator.js');
|
||||||
const shareon = require('shareon');
|
|
||||||
|
|
||||||
function waitFor(obj, property, callback) {
|
function waitFor(obj, property, callback) {
|
||||||
// Wait for a property to exist on window before running callback
|
// Wait for a property to exist on window before running callback
|
||||||
|
@ -53,8 +52,6 @@ $(document).ready(function() {
|
||||||
endAudio: '/audio/ding.mp3',
|
endAudio: '/audio/ding.mp3',
|
||||||
preloadAudio: false,
|
preloadAudio: false,
|
||||||
});
|
});
|
||||||
|
|
||||||
shareon();
|
|
||||||
});
|
});
|
||||||
|
|
||||||
function scrollTo(offset) {
|
function scrollTo(offset) {
|
||||||
|
|
Loading…
Reference in a new issue