Skip to content

Commit

Permalink
v1.1.1 - uncompressed browser bundle is now correctly in development …
Browse files Browse the repository at this point in the history
…mode
  • Loading branch information
insin committed Jan 21, 2015
1 parent f0a22aa commit 5bf6b0e
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 15 deletions.
5 changes: 5 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# 1.1.1 / 2015-01-21

Fixed: uncompressed browser bundle was not actually in development mode, as
documented in README.

# 1.1.0 / 2015-01-18

Added: grid components: `Container`, `Row`, `Col` and `Field`
Expand Down
12 changes: 6 additions & 6 deletions dist/newforms-bootstrap.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* newforms-bootstrap 1.1.0 - https://github.com/insin/newforms-bootstrap
* newforms-bootstrap 1.1.1 - https://github.com/insin/newforms-bootstrap
* MIT Licensed
*/
!function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var o;"undefined"!=typeof window?o=window:"undefined"!=typeof global?o=global:"undefined"!=typeof self&&(o=self),o.BootstrapForm=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
Expand All @@ -24,7 +24,7 @@ var noobj = {}

var warn = function() {}

if ("production" !== "production") {
if ("production" !== "development") {
warn = function(message ) {for (var args=[],$__0=1,$__1=arguments.length;$__0<$__1;$__0++) args.push(arguments[$__0]);
var index = 0
console.warn('[newforms-bootstrap] Warning: ' + message.replace(/%s/g, function() {return args[index++];}))
Expand Down Expand Up @@ -345,28 +345,28 @@ function calculateColumnProps(childProps, options) {
})

if (needColSizeIndexes.length === 0) {
("production" !== "production" ? warn(
("production" !== "development" ? warn(
'[Row %s] All Cols/Fields already have %s column units specified, so ' +
'you don\'t need to use autoColumns.',
rowNum, colProp
) : null)
}
else if (availableCols < 0) {
("production" !== "production" ? warn(
("production" !== "development" ? warn(
'[Row %s] Too many %s column units specified - widths and offsets ' +
'added up to %s.',
rowNum, colProp, 12 - availableCols
) : null)
}
else if (availableCols === 0) {
("production" !== "production" ? warn(
("production" !== "development" ? warn(
'[Row %s] There are no %s column units left to distribute to the %s ' +
'Cols/Fields which needthem.',
rowNum, colProp, needColSizeIndexes.length
) : null)
}
else if (availableCols < needColSizeIndexes.length) {
("production" !== "production" ? warn(
("production" !== "development" ? warn(
'[Row %s] There are more Cols/Fields needing column widths ' +
'(%s) than there are %s column units remaining to distribute (%s).',
rowNum, needColSizeIndexes.length, colProp, availableCols
Expand Down
2 changes: 1 addition & 1 deletion dist/newforms-bootstrap.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 2 additions & 6 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ var gutil = require('gulp-util')
process.env.NODE_ENV = gutil.env.production ? 'production' : 'development'

var pkg = require('./package.json')
var devBuild = gutil.env.production ? '' : ' (dev build at ' + (new Date()).toUTCString() + ')'
var devBuild = gutil.env.release ? '' : ' (dev build at ' + (new Date()).toUTCString() + ')'
var distHeader = '/*!\n\
* <%= pkg.name %> <%= pkg.version %><%= devBuild %> - <%= pkg.homepage %>\n\
* <%= pkg.license %> Licensed\n\
Expand All @@ -24,10 +24,6 @@ var distHeader = '/*!\n\
var jsSrcPaths = './src/**/*.js*'
var jsLibPaths = './lib/**/*.js'

gulp.task('clean-dist', function(cb) {
del('./dist/*.js', cb)
})

gulp.task('clean-lib', function(cb) {
del(jsLibPaths, cb)
})
Expand All @@ -45,7 +41,7 @@ gulp.task('lint-js', ['transpile-js'], function() {
.pipe(jshint.reporter('jshint-stylish'))
})

gulp.task('bundle-js', ['clean-dist', 'lint-js'], function() {
gulp.task('bundle-js', ['lint-js'], function() {
var b = browserify(pkg.main, {
debug: !!gutil.env.debug
, standalone: pkg.standalone
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "newforms-bootstrap",
"description": "Bootstrap integration for newforms",
"version": "1.1.0",
"version": "1.1.1",
"main": "./lib/index.js",
"standalone": "BootstrapForm",
"homepage": "https://github.com/insin/newforms-bootstrap",
Expand Down Expand Up @@ -35,7 +35,7 @@
},
"scripts": {
"debug": "gulp --debug",
"dist": "gulp bundle-js --production",
"dist": "gulp bundle-js --production --release && gulp bundle-js --development --release",
"test": "gulp transpile-js && tape test/*.js",
"watch": "gulp"
},
Expand Down

0 comments on commit 5bf6b0e

Please sign in to comment.