Skip to content

Commit

Permalink
fix browser require
Browse files Browse the repository at this point in the history
  • Loading branch information
mateusmaso committed May 23, 2016
1 parent 4631cd8 commit 41936bd
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 21 deletions.
3 changes: 1 addition & 2 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,7 @@ module.exports = function(grunt) {
},
src: ['spec/**/*.js']
}
},
clean: ['lib', 'dist']
}
});

grunt.loadNpmTasks('grunt-mocha-test');
Expand Down
12 changes: 5 additions & 7 deletions dist/handlebars.binding.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// handlebars.binding
// ------------------
// v0.3.3
// v0.3.4
//
// Copyright (c) 2013-2016 Mateus Maso
// Distributed under MIT license
Expand Down Expand Up @@ -694,6 +694,7 @@ exports.default = deps;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = HandlebarsBinding;

var _handlebars = require("handlebars.element");

Expand Down Expand Up @@ -745,11 +746,9 @@ function HandlebarsBinding(Handlebars) {
}

if (typeof window !== "undefined" && window.Handlebars) {
HandlebarsBinding = HandlebarsBinding(window.Handlebars);
HandlebarsBinding(window.Handlebars);
}

exports.default = HandlebarsBinding;

},{"./bindings":4,"./core":5,"./deps":6,"./utils":8,"handlebars.element":11}],8:[function(require,module,exports){
'use strict';

Expand Down Expand Up @@ -1002,6 +1001,7 @@ arguments[4][6][0].apply(exports,arguments)
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = HandlebarsElement;

var _utils = require('./utils');

Expand Down Expand Up @@ -1047,11 +1047,9 @@ function HandlebarsElement(Handlebars) {
}

if (typeof window !== "undefined" && window.Handlebars) {
HandlebarsElement = HandlebarsElement(window.Handlebars);
HandlebarsElement(window.Handlebars);
}

exports.default = HandlebarsElement;

},{"./core":9,"./deps":10,"./store":12,"./utils":13}],12:[function(require,module,exports){
"use strict";

Expand Down
6 changes: 3 additions & 3 deletions dist/handlebars.binding.min.js

Large diffs are not rendered by default.

5 changes: 2 additions & 3 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = HandlebarsBinding;

var _handlebars = require("handlebars.element");

Expand Down Expand Up @@ -54,7 +55,5 @@ function HandlebarsBinding(Handlebars) {
}

if (typeof window !== "undefined" && window.Handlebars) {
HandlebarsBinding = HandlebarsBinding(window.Handlebars);
HandlebarsBinding(window.Handlebars);
}

exports.default = HandlebarsBinding;
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "handlebars.binding",
"description": "Handlebars plugin for using one-way data binding",
"version": "0.3.3",
"version": "0.3.4",
"author": "mateusmaso",
"license": "MIT",
"keywords": [
Expand All @@ -26,7 +26,7 @@
"url": "http://github.com/mateusmaso/handlebars.binding"
},
"dependencies": {
"handlebars.element": "~0.3.1",
"handlebars.element": "~0.3.2",
"observe-js": "~0.5.7"
},
"scripts": {
Expand Down
6 changes: 2 additions & 4 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import {

import deps from "./deps";

function HandlebarsBinding(Handlebars) {
export default function HandlebarsBinding(Handlebars) {
HandlebarsElement(Handlebars);

var {extend} = Handlebars.Utils;
Expand Down Expand Up @@ -59,7 +59,5 @@ function HandlebarsBinding(Handlebars) {
}

if (typeof window !== "undefined" && window.Handlebars) {
HandlebarsBinding = HandlebarsBinding(window.Handlebars);
HandlebarsBinding(window.Handlebars);
}

export default HandlebarsBinding;

0 comments on commit 41936bd

Please sign in to comment.