diff --git a/package.json b/package.json index a0d09e5..d4a3e73 100644 --- a/package.json +++ b/package.json @@ -23,13 +23,10 @@ }, "devDependencies": { "autoprefixer": "=6.5.0", - "babel-preset-es2015": "=6.13.2", - "babelify": "=7.3.0", "browserify": "=13.1.0", "clean-css": "=3.4.20", "eslint": "=1.5.0", - "eslint-config": "git://github.com/dabapps/eslint-config.git", - "eslint-plugin-react": "=3.4.2", + "eslint-config": "git://github.com/dabapps/eslint-config.git#1.1.4", "markdown-spellcheck": "=0.11.0", "node-sass": "=3.8.0", "nsp": "=2.6.1", diff --git a/plugins/static_build.py b/plugins/static_build.py index c8dc760..53f34b6 100644 --- a/plugins/static_build.py +++ b/plugins/static_build.py @@ -43,7 +43,6 @@ def static_build(*args, **kwargs): run_command('Building jQuery', [node_bin('uglifyjs'), 'node_modules/jquery/dist/jquery.js', UGLIFY_ARGS, '-o', 'theme/static/build/js/jquery.js']) run_command('Building Application', [ node_bin('browserify'), - '-t', '[', 'babelify', '--presets', '[', 'es2015', ']', ']', 'theme/static/src/js/app.js', '-o', 'theme/static/build/js/app.js' ]) diff --git a/theme/static/src/js/app.js b/theme/static/src/js/app.js index adfebec..938fc04 100644 --- a/theme/static/src/js/app.js +++ b/theme/static/src/js/app.js @@ -1,9 +1,9 @@ -import './creative'; -import ansi_up from 'ansi_up'; +require('./creative'); +var ansi_up = require('ansi_up'); $('.image').each(function () { // setup div-image hybrids - const ele = $(this); + var ele = $(this); if (ele.data('image')) { ele.css('background-image', 'url(' + ele.data('image') + ')'); } else { @@ -12,6 +12,6 @@ $('.image').each(function () { // setup div-image hybrids }); $('.ansi-up').each(function () { - const ele = $(this); + var ele = $(this); ele.html(ansi_up.ansi_to_html(ele.html())); }); diff --git a/theme/static/src/js/creative/creative.js b/theme/static/src/js/creative/creative.js index da1676c..17868c7 100644 --- a/theme/static/src/js/creative/creative.js +++ b/theme/static/src/js/creative/creative.js @@ -6,7 +6,7 @@ // jQuery for page scrolling feature - requires jQuery Easing plugin $('a.page-scroll').bind('click', function(event) { - const anchor = $(this); + var anchor = $(this); $('html, body').stop().animate( { scrollTop: ($(anchor.attr('href')).offset().top - 50) diff --git a/theme/static/src/js/creative/index.js b/theme/static/src/js/creative/index.js index 43b0721..80d3f7c 100644 --- a/theme/static/src/js/creative/index.js +++ b/theme/static/src/js/creative/index.js @@ -1,6 +1,6 @@ -import 'jquery.easing'; -import './creative'; +require('jquery.easing'); +require('./creative'); -import WOW from 'wow.js'; +var WOW = require('wow.js'); new WOW().init();