dist/ember-template-compiler.prod.js in ember-source-0.0.9 vs dist/ember-template-compiler.prod.js in ember-source-1.0.0.pre4.0
- old
+ new
@@ -1,9 +1,9 @@
(function() {
/**
@module ember
-@submodule ember-handlebars-compiler
+@submodule ember-handlebars
*/
// Eliminate dependency on any Ember to simplify precompilation workflow
var objectCreate = Object.create || function(parent) {
function F() {}
@@ -15,11 +15,10 @@
if(!Handlebars && typeof require === 'function') {
Handlebars = require('handlebars');
}
-
/**
Prepares the Handlebars templating library for use inside Ember's view
system.
The `Ember.Handlebars` object is the standard Handlebars library, extended to
@@ -32,36 +31,10 @@
@class Handlebars
@namespace Ember
*/
Ember.Handlebars = objectCreate(Handlebars);
-function makeBindings(options) {
- var hash = options.hash,
- hashType = options.hashTypes;
-
- for (var prop in hash) {
- if (hashType[prop] === 'ID') {
- hash[prop + 'Binding'] = hash[prop];
- hashType[prop + 'Binding'] = 'STRING';
- delete hash[prop];
- delete hashType[prop];
- }
- }
-}
-
-Ember.Handlebars.helper = function(name, value) {
- if (Ember.View.detect(value)) {
- Ember.Handlebars.registerHelper(name, function(options) {
-
- makeBindings(options);
- return Ember.Handlebars.helpers.view.call(this, value, options);
- });
- } else {
- Ember.Handlebars.registerBoundHelper.apply(null, arguments);
- }
-}
-
/**
@class helpers
@namespace Ember.Handlebars
*/
Ember.Handlebars.helpers = objectCreate(Handlebars.helpers);
@@ -210,8 +183,8 @@
})();
if (typeof location !== 'undefined' && (location.hostname === 'localhost' || location.hostname === '127.0.0.1')) {
- Ember.Logger.warn("You are running a production build of Ember on localhost and won't receive detailed error messages. "+
+ console.warn("You are running a production build of Ember on localhost and won't receive detailed error messages. "+
"If you want full error messages please use the non-minified build provided on the Ember website.");
}