From 9eded912a05082a89ef30b899bbe659cb9ce254c Mon Sep 17 00:00:00 2001 From: XhmikosR Date: Sat, 19 Sep 2015 10:26:12 +0300 Subject: [PATCH] Make jQuery 2.0 the minimum supported version. --- Gruntfile.js | 4 ++-- bower.json | 2 +- grunt/configBridge.json | 16 ---------------- 3 files changed, 3 insertions(+), 19 deletions(-) diff --git a/Gruntfile.js b/Gruntfile.js index f3f3887662..c80834aa38 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -46,8 +46,8 @@ module.exports = function (grunt) { '}\n', jqueryVersionCheck: '+function ($) {\n' + ' var version = $.fn.jquery.split(\' \')[0].split(\'.\')\n' + - ' if ((version[0] < 2 && version[1] < 9) || (version[0] == 1 && version[1] == 9 && version[2] < 1)) {\n' + - ' throw new Error(\'Bootstrap\\\'s JavaScript requires jQuery version 1.9.1 or higher\')\n' + + ' if (version[0] !== \'2\') {\n' + + ' throw new Error(\'Bootstrap\\\'s JavaScript requires jQuery version 2.x.x\')\n' + ' }\n' + '}(jQuery);\n\n', diff --git a/bower.json b/bower.json index 0d24a6392c..b7e9f645f2 100644 --- a/bower.json +++ b/bower.json @@ -29,6 +29,6 @@ "test-infra" ], "dependencies": { - "jquery": "1.9.1 - 2" + "jquery": "2" } } diff --git a/grunt/configBridge.json b/grunt/configBridge.json index 250aa16772..7b965bbb5d 100644 --- a/grunt/configBridge.json +++ b/grunt/configBridge.json @@ -7,21 +7,5 @@ "../assets/js/vendor/tether.min.js", "../assets/js/src/application.js" ] - }, - "config": { - "jqueryCheck": [ - "if (typeof jQuery === 'undefined') {", - " throw new Error('Bootstrap\\'s JavaScript requires jQuery')", - "}\n" - ], - "jqueryVersionCheck": [ - "+function ($) {", - " 'use strict';", - " var version = $.fn.jquery.split(' ')[0].split('.')", - " if ((version[0] < 2 && version[1] < 9) || (version[0] == 1 && version[1] == 9 && version[2] < 1) || (version[0] > 2)) {", - " throw new Error('Bootstrap\\'s JavaScript requires jQuery version 1.9.1 or higher, but lower than version 3')", - " }", - "}(jQuery);\n\n" - ] } }