language stringclasses 1
value | owner stringlengths 2 15 | repo stringlengths 2 21 | sha stringlengths 45 45 | message stringlengths 7 36.3k | path stringlengths 1 199 | patch stringlengths 15 102k | is_multipart bool 2
classes |
|---|---|---|---|---|---|---|---|
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | bin/publish_builds | @@ -9,7 +9,7 @@ if [ "$TRAVIS_PULL_REQUEST" == "false" ]; then
DISABLE_JSCS=true DISABLE_JSHINT=true ember build --environment=production
fi
- npm run docs # generate documentation to be published
+ npm run docs # Generate documentation to be published.
./bin/publish_to_s3.js
./bin/bower_ember_build
... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | bin/publish_to_s3.js | @@ -9,7 +9,7 @@
// S3_SECRET_ACCESS_KEY
// S3_ACCESS_KEY_ID
//
-// Once you have those you execute with the following:
+// Once you have those, you execute with the following:
//
// ```sh
// ./bin/publish_to_s3.js | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | bin/run-node-tests.js | @@ -2,7 +2,7 @@
global.QUnit = require('qunitjs');
-// adds test reporting
+// Adds test reporting.
var qe = require('qunit-extras');
qe.runInContext(global);
| true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | bin/run-sauce-tests.js | @@ -38,7 +38,7 @@ RSVP.resolve()
return run('./node_modules/.bin/ember', [ 'sauce:connect' ]);
})
.then(function() {
- // calling testem directly here instead of `ember test` so that
+ // Calling testem directly here instead of `ember test` so that
// we do not have to do a double build (by the ti... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | bin/run-tests.js | @@ -10,17 +10,17 @@ var finalhandler = require('finalhandler')
var http = require('http')
var serveStatic = require('serve-static')
-// Serve up public/ftp folder
+// Serve up public/ftp folder.
var serve = serveStatic('./dist/', {'index': ['index.html', 'index.htm']})
-// Create server
+// Create server.
var s... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | lib/jscs-rules/disallow-const-outside-module-scope.js | @@ -14,12 +14,12 @@ module.exports.prototype = {
check: function(file, errors) {
file.iterateNodesByType('VariableDeclaration', function(node) {
if (node.parentNode.type === 'Program') {
- // declaration is in root of module
+ // Declaration is in root of module.
return;
}
... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | lib/jscs-rules/disallow-multiple-var-decl-with-assignment.js | @@ -20,7 +20,7 @@ module.exports.prototype = {
check: function(file, errors) {
file.iterateNodesByType('VariableDeclaration', function(node) {
- // allow multiple var declarations in for statement
+ // Allow multiple var declarations in for statement
// for (var i = 0, j = myArray.length; i <... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/container/lib/container.js | @@ -95,7 +95,7 @@ Container.prototype = {
twitter === twitter2; //=> true
```
- If singletons are not wanted an optional flag can be provided at lookup.
+ If singletons are not wanted, an optional flag can be provided at lookup.
```javascript
var registry = new Registry();
@@ -122,7 +122,7 @@ Co... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/container/lib/index.js | @@ -1,14 +1,14 @@
import Ember from 'ember-metal/core';
/*
-Public api for the container is still in flux.
-The public api, specified on the application namespace should be considered the stable api.
+Public API for the container is still in flux.
+The public API, specified on the application namespace should be co... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/container/lib/owner.js | @@ -42,8 +42,8 @@ export const OWNER = symbol('OWNER');
```
@method getOwner
- @param {Object} object A object with an owner.
- @return {Object} an owner object.
+ @param {Object} object An object with an owner.
+ @return {Object} An owner object.
@for Ember
@public
*/
@@ -56,8 +56,8 @@ export functi... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-application/tests/system/application_instance_test.js | @@ -146,5 +146,5 @@ QUnit.test('unregistering a factory clears all cached instances of that factory'
let postController2 = appInstance.lookup('controller:post');
assert.ok(postController2, 'lookup creates instance');
- assert.notStrictEqual(postController1, postController2, 'lookup creates a brand new instance... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-application/tests/system/application_test.js | @@ -63,7 +63,7 @@ QUnit.test('you cannot make a new application that is a parent of an existing ap
});
});
-QUnit.test('you cannot make a new application that is a descendent of an existing application', function() {
+QUnit.test('you cannot make a new application that is a descendant of an existing application', ... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-application/tests/system/dependency_injection/default_resolver_test.js | @@ -63,7 +63,7 @@ QUnit.test('the default resolver looks up templates in Ember.TEMPLATES', functio
});
QUnit.test('the default resolver looks up basic name as no prefix', function() {
- ok(Controller.detect(locator.lookup('controller:basic')), 'locator looksup correct controller');
+ ok(Controller.detect(locator.... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-application/tests/system/engine_instance_test.js | @@ -52,5 +52,5 @@ QUnit.test('unregistering a factory clears all cached instances of that factory'
let postController2 = engineInstance.lookup('controller:post');
assert.ok(postController2, 'lookup creates instance');
- assert.notStrictEqual(postController1, postController2, 'lookup creates a brand new instanc... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-application/tests/system/initializers_test.js | @@ -34,7 +34,7 @@ QUnit.test('initializers require proper \'name\' and \'initialize\' properties',
});
if (isEnabled('ember-application-visit')) {
- QUnit.test('initializers that thorws causes the boot promise to reject with the error', function() {
+ QUnit.test('initializers that throw errors cause the boot prom... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-application/tests/system/instance_initializers_test.js | @@ -360,7 +360,7 @@ QUnit.test('initializers are run before ready hook', function() {
});
});
-QUnit.test('initializers should be executed in their own context', function() {
+QUnit.test('initializers are executed in their own context', function() {
expect(1);
var MyApplication = Application.extend();
@@ ... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-application/tests/system/reset_test.js | @@ -37,7 +37,7 @@ QUnit.test('Brings its own run-loop if not provided', function() {
application.reset();
});
-QUnit.test('does not bring its own run loop if one is already provided', function() {
+QUnit.test('Does not bring its own run loop if one is already provided', function() {
expect(3);
var didBeco... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-application/tests/system/visit_test.js | @@ -118,7 +118,7 @@ if (isEnabled('ember-application-visit')) {
});
});
- QUnit.test('calling visit() on app without first calling boot() should boot the app', function(assert) {
+ QUnit.test('calling visit() on an app without first calling boot() should boot the app', function(assert) {
let appBooted ... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-debug/lib/handlers.js | @@ -6,7 +6,7 @@ export let HANDLERS = { };
export function generateTestAsFunctionDeprecation(source) {
return `Calling \`${source}\` with a function argument is deprecated. Please ` +
`use \`!!Constructor\` for constructors, or an \`IIFE\` to compute the test for deprecation. ` +
- `In a future version func... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-debug/lib/index.js | @@ -112,7 +112,7 @@ setDebugFunction('info', function info() {
@param {String} message A description of the deprecation.
@param {Object} [options] The options object for Ember.deprecate.
@param {Function} func The new function called to replace its deprecated counterpart.
- @return {Function} a new function t... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-debug/lib/warn.js | @@ -31,7 +31,7 @@ export let missingOptionsIdDeprecation = 'When calling `Ember.warn` you must pro
@param {String} message A warning to display.
@param {Boolean} test An optional boolean. If falsy, the warning
will be displayed.
- @param {Object} options An ojbect that can be used to pass a unique
+ @param... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-debug/tests/main_test.js | @@ -46,7 +46,7 @@ QUnit.test('Ember.deprecate does not throw if RAISE_ON_DEPRECATION is false', fu
}
});
-QUnit.test('Ember.deprecate re-sets deprecation level to RAISE if ENV.RAISE_ON_DEPRECATION is set', function(assert) {
+QUnit.test('Ember.deprecate resets deprecation level to RAISE if ENV.RAISE_ON_DEPRECATIO... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-extension-support/lib/container_debug_adapter.js | @@ -28,7 +28,7 @@ import EmberObject from 'ember-runtime/system/object';
* `catalogEntriesByType`
The adapter will need to be registered
- in the application's container as `container-debug-adapter:main`
+ in the application's container as `container-debug-adapter:main`.
Example:
@@ -65,7 +65,7 @@ expo... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-extension-support/lib/data_adapter.js | @@ -35,7 +35,7 @@ import { getOwner } from 'container/owner';
* `observeRecord`
The adapter will need to be registered
- in the application's container as `dataAdapter:main`
+ in the application's container as `dataAdapter:main`.
Example:
@@ -72,7 +72,7 @@ export default EmberObject.extend({
contain... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-extension-support/tests/container_debug_adapter_test.js | @@ -1,6 +1,6 @@
import run from 'ember-metal/run_loop';
import EmberController from 'ember-runtime/controllers/controller';
-import 'ember-extension-support'; // Must be required to export Ember.ContainerDebugAdapter
+import 'ember-extension-support'; // Must be required to export Ember.ContainerDebugAdapter.
import... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/helper.js | @@ -13,7 +13,7 @@ import Object from 'ember-runtime/system/object';
<div>{{format-currency cents currency="$"}}</div>
```
- Additionally a helper can be called as a nested helper (sometimes called a
+ Additionally, a helper can be called as a nested helper (sometimes called a
subexpression). In this exampl... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/helpers.js | @@ -21,7 +21,7 @@ var helpers = new EmptyObject();
@method _registerHelper
@for Ember.HTMLBars
@param {String} name
- @param {Object|Function} helperFunc the helper function to add
+ @param {Object|Function} helperFunc The helper function to add.
*/
export function registerHelper(name, helperFunc) {
hel... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/helpers/-join-classes.js | @@ -1,5 +1,5 @@
/*
- this private helper is used to join and compact a list of class names
+ This private helper is used to join and compact a list of class names.
@private
*/ | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/helpers/-legacy-each-with-controller.js | @@ -7,7 +7,7 @@ export default function legacyEachWithControllerHelper(params, hash, blocks) {
var list = params[0];
var keyPath = hash.key;
- // TODO: Correct falsy semantics
+ // TODO: Correct falsy semantics.
if (!list || get(list, 'length') === 0) {
if (blocks.inverse.yield) { blocks.inverse.yield... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/helpers/-normalize-class.js | @@ -15,7 +15,7 @@ export default function normalizeClass(params, hash) {
var { activeClass, inactiveClass } = hash;
// When using the colon syntax, evaluate the truthiness or falsiness
- // of the value to determine which className to return
+ // of the value to determine which className to return.
if (act... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/helpers/loc.js | @@ -33,7 +33,7 @@ import { loc } from 'ember-runtime/system/string';
@method loc
@for Ember.Templates.helpers
- @param {String} str The string to format
+ @param {String} str The string to format.
@see {Ember.String#loc}
@public
*/ | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/hooks/component.js | @@ -51,7 +51,7 @@ export default function componentHook(renderNode, env, scope, _tagName, params,
}
}
- // Determine if this is an initial render or a re-render
+ // Determine if this is an initial render or a re-render.
if (state.manager) {
state.manager.rerender(env, attrs, visitor);
return;
... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/hooks/get-cell-or-value.js | @@ -3,10 +3,10 @@ import { MUTABLE_REFERENCE } from 'ember-htmlbars/keywords/mut';
export default function getCellOrValue(ref) {
if (ref && ref[MUTABLE_REFERENCE]) {
- // reify the mutable reference into a mutable cell
+ // Reify the mutable reference into a mutable cell.
return ref.cell();
}
- /... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/hooks/get-child.js | @@ -10,7 +10,7 @@ export default function getChild(parent, key) {
return parent.getKey(key);
}
- // This should only happen when we are looking at an `attrs` hash
+ // This should only happen when we are looking at an `attrs` hash.
// That might change if it is possible to pass object literals
// thro... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/hooks/invoke-helper.js | @@ -4,10 +4,10 @@ import subscribe from 'ember-htmlbars/utils/subscribe';
export default function invokeHelper(morph, env, scope, visitor, params, hash, helper, templates, context) {
var helperStream = buildHelperStream(helper, params, hash, templates, env, scope);
- // Ember.Helper helpers are pure values, thus... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/hooks/link-render-node.js | @@ -30,7 +30,7 @@ export default function linkRenderNode(renderNode, env, scope, path, params, has
}
}
- // If has a dot in the path, we need to subscribe to the arguments in the
+ // If there is a dot in the path, we need to subscribe to the arguments in the
// closure component as well.
if (CONTAI... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/hooks/will-cleanup-tree.js | @@ -3,7 +3,7 @@ export default function willCleanupTree(env) {
// When we go to clean up the render node and all of its children, we may
// encounter views/components associated with those nodes along the way. In
- // those cases, we need to make sure we need to sever the link between the
+ // those cases, we... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/index.js | @@ -133,12 +133,12 @@ import {
setTemplates
} from 'ember-htmlbars/template_registry';
-// importing adds template bootstrapping
-// initializer to enable embedded templates
+// Importing adds template bootstrapping
+// initializer to enable embedded templates.
import 'ember-htmlbars/system/bootstrap';
-// imp... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/keywords.js | @@ -21,7 +21,7 @@ var keywords = Object.create(hooks.keywords);
@method _registerHelper
@for Ember.HTMLBars
@param {String} name
- @param {Object|Function} keyword the keyword to add
+ @param {Object|Function} keyword The keyword to add.
*/
export function registerKeyword(name, keyword) {
keywords[name]... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/keywords/closure-component.js | @@ -40,9 +40,9 @@ export default function closureComponent(env, [path, ...params], hash) {
s.addDependency(path);
// FIXME: If the stream invalidates on every params or hash change, then
- // the {{component helper will be forces to rerender the whole component
+ // the {{component helper will be forced to re... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/keywords/collection.js | @@ -35,7 +35,7 @@ import assign from 'ember-metal/assign';
```javascript
App = Ember.Application.create();
App.ApplicationRoute = Ember.Route.extend({
- model: function() {
+ model() {
return [{name: 'Yehuda'},{name: 'Tom'},{name: 'Peter'}];
}
});
@@ -53,8 +53,8 @@ import assign from 'embe... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/keywords/get.js | @@ -22,7 +22,7 @@ function labelFor(source, key) {
let DynamicKeyStream = BasicStream.extend({
init(source, keySource) {
- // used to get the original path for debugging purposes
+ // Used to get the original path for debugging purposes.
var label = labelFor(source, keySource);
this.label = labe... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/keywords/legacy-yield.js | @@ -5,7 +5,7 @@ export default function legacyYield(morph, env, _scope, params, hash, template,
let block = scope.getBlock('default');
if (block.arity === 0) {
- // Typically, the `controller` local is persists through lexical scope.
+ // Typically, the `controller` local persists through lexical scope.
... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/keywords/mut.js | @@ -62,7 +62,7 @@ let MutStream = ProxyStream.extend({
```javascript
// my-child.js
export default Component.extend({
- click: function() {
+ click() {
this.attrs.childClickCount.update(this.attrs.childClickCount.value + 1);
}
}); | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/keywords/outlet.js | @@ -12,7 +12,7 @@ import isEnabled from 'ember-metal/features';
topLevelViewTemplate.meta.revision = 'Ember@VERSION_STRING_PLACEHOLDER';
/**
- The `{{outlet}}` helper lets you specify where a child routes will render in
+ The `{{outlet}}` helper lets you specify where a child route will render in
your template... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/keywords/partial.js | @@ -43,7 +43,7 @@ import { internal } from 'htmlbars-runtime';
@method partial
@for Ember.Templates.helpers
- @param {String} partialName the name of the template to render minus the leading underscore
+ @param {String} partialName The name of the template to render minus the leading underscore.
@public
*... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/system/append-templated-view.js | @@ -22,7 +22,6 @@ export default function appendTemplatedView(parentView, morph, viewClassOrInstan
// We only want to override the `_context` computed property if there is
// no specified controller. See View#_context for more information.
-
var noControllerInProto = !viewProto.controller;
if (viewProto.c... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/system/bootstrap.js | @@ -42,7 +42,7 @@ function bootstrap(ctx) {
jQuery(selectors, ctx)
.each(function() {
- // Get a reference to the script tag
+ // Get a reference to the script tag.
var script = jQuery(this);
// Get the name of the script, used by Ember.View's templateName property.
@@ -60,15 +60,15 @@ funct... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/system/instrumentation-support.js | @@ -9,10 +9,10 @@ import {
Wrap your node manager's render and re-render methods
with this function.
- @param {Object} component Component or View instance (optional)
- @param {Function} callback The function to instrument
- @param {Object} context The context to call the function with
- @return {Object} Re... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/system/lookup-helper.js | @@ -23,13 +23,13 @@ export function validateLazyHelperName(helperName, container, keywords) {
* Look for a registered helper
* If a dash exists in the name:
- * Look for a helper registed in the container
+ * Look for a helper registed in the container.
* Use Ember.ComponentLookup to find an Ember.Co... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/system/make_bound_helper.js | @@ -7,7 +7,7 @@ import { helper } from 'ember-htmlbars/helper';
/**
Create a bound helper. Accepts a function that receives the ordered and hash parameters
- from the template. If a bound property was provided in the template it will be resolved to its
+ from the template. If a bound property was provided in th... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/template_registry.js | @@ -1,6 +1,6 @@
// STATE within a module is frowned apon, this exists
// to support Ember.TEMPLATES but shield ember internals from this legacy
-// global API
+// global API.
let TEMPLATES = {};
export function setTemplates(templates) { | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/utils/is-component.js | @@ -42,7 +42,7 @@ export default function isComponent(env, scope, path) {
let moduleName = env.meta && env.meta.moduleName;
if (!moduleName) {
- // without a source moduleName we can not perform local lookups
+ // Without a source moduleName, we can not perform local lookups.
... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-htmlbars/lib/utils/string.js | @@ -19,7 +19,7 @@ import { SafeString, escapeExpression } from 'htmlbars-util';
@method htmlSafe
@for Ember.String
@static
- @return {Handlebars.SafeString} a string that will not be html escaped by Handlebars
+ @return {Handlebars.SafeString} A string that will not be HTML escaped by Handlebars.
@public
... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-metal-views/lib/htmlbars-renderer.js | @@ -45,7 +45,7 @@ Renderer.prototype.prerenderTopLevelView =
Renderer.prototype.renderTopLevelView =
function Renderer_renderTopLevelView(view, renderNode) {
- // Check to see if insertion has been canceled
+ // Check to see if insertion has been canceled.
if (view._willInsert) {
view._willInser... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-metal/lib/alias.js | @@ -76,6 +76,6 @@ function AliasedProperty_oneWaySet(obj, keyName, value) {
return set(obj, keyName, value);
}
-// Backwards compatibility with Ember Data
+// Backwards compatibility with Ember Data.
AliasedProperty.prototype._meta = undefined;
AliasedProperty.prototype.meta = ComputedProperty.prototype.meta; | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-metal/lib/binding.js | @@ -99,7 +99,7 @@ Binding.prototype = {
`get()` - see that method for more information.
@method from
- @param {String} path the property path to connect to
+ @param {String} path The property path to connect to.
@return {Ember.Binding} `this`
@public
*/
@@ -118,7 +118,7 @@ Binding.prototy... | true |
Other | emberjs | ember.js | 36bb816ae8fac449a09916a5c65cd5049d93bdc4.json | Fix misc typos and grammar | packages/ember-metal/lib/streams/utils.js | @@ -2,13 +2,13 @@ import { assert } from 'ember-metal/debug';
import BasicStream, { Stream } from './stream';
/*
- Check whether an object is a stream or not
+ Check whether an object is a stream or not.
@private
@for Ember.stream
@function isStream
- @param {Object|Stream} object object to check whether it... | true |
Other | emberjs | ember.js | a0b7b680f2eaec53580b628ecd7eab2b42ba2abb.json | Build script improvements
- [x] The current verison of phantomjs no longer prints noisy messages
to stderr, dropping the check
- [x] Don't supress phantomjs error message when it crashes
- [x] Retry up to 3 times when phantomjs crashes
- [x] Use `minidump_stackwalk` to print the phantomjs stack trace when
... | .travis.yml | @@ -10,18 +10,33 @@ cache:
- node_modules
- bower_components
- persistent-filter-caches
+ - phantomjs
before_install:
- "npm config set spin false"
- "npm --version"
- "phantomjs --version"
+ - "rm -f /tmp/*.dmp"
+ - "mkdir -p phantomjs"
+ - >
+ if [ ! -d ./phantomjs/`phantomjs --ver... | true |
Other | emberjs | ember.js | a0b7b680f2eaec53580b628ecd7eab2b42ba2abb.json | Build script improvements
- [x] The current verison of phantomjs no longer prints noisy messages
to stderr, dropping the check
- [x] Don't supress phantomjs error message when it crashes
- [x] Retry up to 3 times when phantomjs crashes
- [x] Use `minidump_stackwalk` to print the phantomjs stack trace when
... | bin/run-tests.js | @@ -6,21 +6,6 @@ var chalk = require('chalk');
var packages = require('../lib/packages');
var runInSequence = require('../lib/run-in-sequence');
-function shouldPrint(inputString) {
- var skipStrings = [
- "*** WARNING: Method userSpaceScaleFactor",
- "CoreText performance note:",
- ];
-
- for (var i = 0; ... | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-application/lib/system/application-instance.js | @@ -11,7 +11,7 @@ import run from 'ember-metal/run_loop';
import { computed } from 'ember-metal/computed';
import DOMHelper from 'ember-htmlbars/system/dom-helper';
import { buildFakeRegistryWithDeprecations } from 'ember-runtime/mixins/registry_proxy';
-import Renderer from 'ember-metal-views/renderer';
+import { R... | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-application/lib/system/application.js | @@ -9,7 +9,7 @@ import { get } from 'ember-metal/property_get';
import { runLoadHooks } from 'ember-runtime/system/lazy_load';
import run from 'ember-metal/run_loop';
import Controller from 'ember-runtime/controllers/controller';
-import Renderer from 'ember-metal-views/renderer';
+import { Renderer } from 'ember-me... | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-glimmer/lib/ember-metal-views/index.js | @@ -0,0 +1,18 @@
+export class Renderer {
+ constructor(domHelper, { destinedForDOM, env } = {}) {
+ this._dom = domHelper;
+ this._env = env;
+ }
+
+ appendTo(view, target) {
+ let env = this._env;
+
+ env.begin();
+ view.template.render({ view }, env, { appendTo: target });
+ env.commit();
+ }
+... | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-glimmer/lib/ember-template-compiler/system/compile.js | @@ -0,0 +1,22 @@
+import template from './template';
+import require, { has } from 'require';
+
+let compileSpec;
+let Template;
+
+export default function compile(string, options) {
+ if (!compileSpec && has('glimmer-compiler')) {
+ compileSpec = require('glimmer-compiler').compileSpec;
+ }
+
+ if (!Template && ... | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-glimmer/lib/ember-template-compiler/system/template.js | @@ -0,0 +1,3 @@
+export default function template(templateSpec) {
+ return JSON.parse(templateSpec);
+} | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-glimmer/tests/dummy_test.js | @@ -1,8 +0,0 @@
-QUnit.module('ember-glimmer: main');
-
-QUnit.test('dummy test', function() {
- // The test runner will exit with error if we don't have any tests in the
- // package, so this is to convince the runner that everything is okay.
- // Remove me once we started testing real things.
- ok(true, 'it works... | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-glimmer/tests/integration/content-test.js | @@ -0,0 +1,10 @@
+import { RenderingTest, moduleFor } from '../utils/test-case';
+
+moduleFor('Content tests', class extends RenderingTest {
+
+ ['TEST: it can render static content']() {
+ this.render('hello');
+ this.assertText('hello');
+ }
+
+}); | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-glimmer/tests/utils/environment.js | @@ -0,0 +1 @@
+export { TestEnvironment as default } from 'glimmer-test-helpers'; | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-glimmer/tests/utils/helpers.js | @@ -0,0 +1,3 @@
+export { DOMHelper } from 'glimmer-runtime';
+export { Renderer } from 'ember-glimmer/ember-metal-views';
+export { default as compile } from 'ember-glimmer/ember-template-compiler/system/compile'; | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-glimmer/tests/utils/package-name.js | @@ -0,0 +1 @@
+export default 'glimmer'; | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-glimmer/tests/utils/test-case.js | @@ -0,0 +1,75 @@
+import packageName from './package-name';
+import Environment from './environment';
+import { compile, DOMHelper, Renderer } from './helpers';
+import { runAppend, runDestroy } from 'ember-runtime/tests/utils';
+import Component from 'ember-views/components/component';
+import jQuery from 'ember-views... | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-htmlbars/lib/system/render-env.js | @@ -1,5 +1,5 @@
import defaultEnv from 'ember-htmlbars/env';
-import { MorphSet } from 'ember-metal-views/renderer';
+import { MorphSet } from 'ember-metal-views';
import { getOwner } from 'container/owner';
export default function RenderEnv(options) { | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-htmlbars/tests/attr_nodes/data_test.js | @@ -2,7 +2,7 @@ import EmberView from 'ember-views/views/view';
import run from 'ember-metal/run_loop';
import EmberObject from 'ember-runtime/system/object';
import compile from 'ember-template-compiler/system/compile';
-import Renderer from 'ember-metal-views/renderer';
+import { Renderer } from 'ember-metal-views... | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-metal-views/lib/htmlbars-renderer.js | @@ -6,7 +6,7 @@ import setProperties from 'ember-metal/set_properties';
import buildComponentTemplate from 'ember-views/system/build-component-template';
import environment from 'ember-metal/environment';
-function Renderer(domHelper, destinedForDOM) {
+export function Renderer(domHelper, { destinedForDOM } = {}) {... | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-metal-views/lib/index.js | @@ -1,2 +1 @@
-import Renderer from 'ember-metal-views/renderer';
-export { Renderer };
+export * from './htmlbars-renderer'; | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-views/lib/index.js | @@ -17,7 +17,7 @@ import {
states
} from 'ember-views/views/states';
-import Renderer from 'ember-metal-views/renderer';
+import { Renderer } from 'ember-metal-views';
import { DeprecatedCoreView } from 'ember-views/views/core_view';
import { DeprecatedView } from 'ember-views/views/view';
import { DeprecatedC... | true |
Other | emberjs | ember.js | b8786badc7dd018487ac131283a4a462fcbd6e49.json | Add a basic integration test for Glimmer
This also setup that new testing infrastructure
that would allow us to run the same tests on both
Glimmer and HTMLBars. | packages/ember-views/lib/views/core_view.js | @@ -6,7 +6,7 @@ import Evented from 'ember-runtime/mixins/evented';
import ActionHandler, { deprecateUnderscoreActions } from 'ember-runtime/mixins/action_handler';
import { typeOf } from 'ember-runtime/utils';
-import Renderer from 'ember-metal-views/renderer';
+import { Renderer } from 'ember-metal-views';
impor... | true |
Other | emberjs | ember.js | 3d791dd0c9bb6b5190ae218cf2639e5e49bd4285.json | Add a toggle for hidding skipped tests | testem.dist.json | @@ -1,6 +1,6 @@
{
"framework": "qunit",
- "test_page": "dist/tests/index.html?hidepassed",
+ "test_page": "dist/tests/index.html?hidepassed&hideskipped",
"timeout": 540,
"parallel": 4,
"disable_watching": true, | true |
Other | emberjs | ember.js | 3d791dd0c9bb6b5190ae218cf2639e5e49bd4285.json | Add a toggle for hidding skipped tests | tests/index.html | @@ -4,6 +4,11 @@
<meta charset="utf-8">
<title>Ember</title>
<link rel="stylesheet" href="../qunit/qunit.css">
+ <style type="text/css">
+ #qunit-tests.hideskipped li.skipped {
+ display: none;
+ }
+ </style>
<script src="../qunit/qunit.js"></script>
<script src="/testem.... | true |
Other | emberjs | ember.js | 978b11dd3d1ed89700e82cfac94778fe187c5850.json | Use master of glimmer for integration efforts.
We will lock this down when we have made more progress. | package.json | @@ -32,7 +32,7 @@
"express": "^4.5.0",
"finalhandler": "^0.4.0",
"github": "^0.2.3",
- "glimmer-engine": "tildeio/glimmer#integration",
+ "glimmer-engine": "tildeio/glimmer#master",
"glob": "~4.3.2",
"htmlbars": "0.14.13",
"qunit-extras": "^1.4.0", | false |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/container/lib/container.js | @@ -185,10 +185,7 @@ function isSingleton(container, fullName) {
return container.registry.getOption(fullName, 'singleton') !== false;
}
-function lookup(container, _fullName, _options) {
- let options = _options || {};
- let fullName = _fullName;
-
+function lookup(container, fullName, options = {}) {
if (i... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/container/lib/registry.js | @@ -168,7 +168,7 @@ Registry.prototype = {
@param {Function} factory
@param {Object} options
*/
- register(fullName, factory, options) {
+ register(fullName, factory, options = {}) {
assert('fullName must be a proper full name', this.validateFullName(fullName));
if (factory === undefined) {
@@... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-htmlbars/lib/node-managers/component-node-manager.js | @@ -35,16 +35,14 @@ export default ComponentNodeManager;
ComponentNodeManager.create = function ComponentNodeManager_create(renderNode, env, options) {
let { tagName,
params,
- attrs,
+ attrs = {},
parentView,
parentScope,
isAngleBracket,
component,
... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-htmlbars/tests/glimmer-component/render-test.js | @@ -40,9 +40,7 @@ if (isEnabled('ember-htmlbars-component-generation')) {
}
function renderComponent(tag, component) {
- let { params, hash, yielded, implementation } = component;
- params = params || [];
- hash = hash || {};
+ let { params = [], hash = {}, yielded, implementation } = component;
let stringPa... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-htmlbars/tests/helpers/loc_test.js | @@ -3,10 +3,10 @@ import EmberView from 'ember-views/views/view';
import compile from 'ember-template-compiler/system/compile';
import { runAppend, runDestroy } from 'ember-runtime/tests/utils';
-function buildView(template, context) {
+function buildView(template, context = {}) {
return EmberView.create({
... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-routing/tests/system/router_test.js | @@ -9,9 +9,7 @@ import { setOwner } from 'container/owner';
var owner;
-function createRouter(settings, options) {
- options = options || {};
-
+function createRouter(settings, options = {}) {
var CustomRouter = Router.extend();
var router = CustomRouter.create(settings);
| true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-runtime/lib/mixins/target_action_support.js | @@ -113,8 +113,7 @@ var TargetActionSupport = Mixin.create({
@return {Boolean} true if the action was sent successfully and did not return false
@private
*/
- triggerAction(opts) {
- opts = opts || {};
+ triggerAction(opts = {}) {
var action = opts.action || get(this, 'action');
var target = opt... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-runtime/lib/system/native_array.js | @@ -137,10 +137,9 @@ var A;
if (Ember.EXTEND_PROTOTYPES === true || Ember.EXTEND_PROTOTYPES.Array) {
NativeArray.apply(Array.prototype);
- A = function (arr) { return arr || []; };
+ A = function (arr = []) { return arr; };
} else {
- A = function (arr) {
- if (arr === undefined) { arr = []; }
+ A = funct... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-runtime/tests/mixins/array_test.js | @@ -17,8 +17,8 @@ var TestArray = EmberObject.extend(EmberArray, {
_content: null,
- init(ary) {
- this._content = ary || [];
+ init(ary = []) {
+ this._content = ary;
},
// some methods to modify the array so we can test changes. Note that | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-runtime/tests/mixins/enumerable_test.js | @@ -18,8 +18,8 @@ var TestEnumerable = EmberObject.extend(Enumerable, {
_content: null,
- init(ary) {
- this._content = ary || [];
+ init(ary = []) {
+ this._content = ary;
},
addObject(obj) {
@@ -347,4 +347,3 @@ QUnit.test('removing enumerable observer should disable', function() {
obj.enumer... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-runtime/tests/mixins/mutable_array_test.js | @@ -12,8 +12,8 @@ var TestMutableArray = EmberObject.extend(MutableArray, {
_content: null,
- init(ary) {
- this._content = emberA(ary || []);
+ init(ary = []) {
+ this._content = emberA(ary);
},
replace(idx, amt, objects) { | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-template-compiler/lib/plugins/assert-no-view-and-controller-paths.js | @@ -2,10 +2,10 @@ import Ember from 'ember-metal/core';
import { assert } from 'ember-metal/debug';
import calculateLocationDisplay from 'ember-template-compiler/system/calculate-location-display';
-function AssertNoViewAndControllerPaths(options) {
+function AssertNoViewAndControllerPaths(options = {}) {
// set... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-template-compiler/lib/plugins/assert-no-view-helper.js | @@ -2,10 +2,10 @@ import Ember from 'ember-metal/core';
import { assert } from 'ember-metal/debug';
import calculateLocationDisplay from 'ember-template-compiler/system/calculate-location-display';
-function AssertNoViewHelper(options) {
+function AssertNoViewHelper(options = {}) {
// set later within HTMLBars t... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-template-compiler/lib/plugins/transform-each-in-to-hash.js | @@ -22,10 +22,10 @@
@class TransformEachInToHash
@private
*/
-function TransformEachInToHash(options) {
+function TransformEachInToHash(options = {}) {
// set later within HTMLBars to the syntax package
this.syntax = null;
- this.options = options || {};
+ this.options = options;
}
/** | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-template-compiler/lib/plugins/transform-input-on-to-onEvent.js | @@ -24,10 +24,10 @@ import calculateLocationDisplay from 'ember-template-compiler/system/calculate-l
@private
@class TransformInputOnToOnEvent
*/
-function TransformInputOnToOnEvent(options) {
+function TransformInputOnToOnEvent(options = {}) {
// set later within HTMLBars to the syntax package
this.syntax... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-template-compiler/lib/system/calculate-location-display.js | @@ -1,5 +1,4 @@
-export default function calculateLocationDisplay(moduleName, _loc) {
- let loc = _loc || {};
+export default function calculateLocationDisplay(moduleName, loc = {}) {
let { column, line } = loc.start || {};
let moduleInfo = '';
if (moduleName) { | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | packages/ember-views/lib/mixins/view_child_views_support.js | @@ -81,7 +81,7 @@ export default Mixin.create({
@return {Ember.View} new instance
@private
*/
- createChildView(maybeViewClass, _attrs) {
+ createChildView(maybeViewClass, attrs = {}) {
if (!maybeViewClass) {
throw new TypeError('createChildViews first argument must exist');
}
@@ -92,7 +... | true |
Other | emberjs | ember.js | 586d4c6ab0a82abee0df1f331121e9c99433770e.json | Use default parameters
Move to default parameters where appropriate | tests/node/component-rendering-test.js | @@ -44,11 +44,11 @@ QUnit.test("Component with dynamic value", function(assert) {
assert.ok(html.match(/<h1>Hello World<\/h1>/));
});
-function buildComponent(template, props) {
+function buildComponent(template, props = {}) {
var Component = Ember.Component.extend({
renderer: new Ember._Renderer(new DOMH... | true |
Other | emberjs | ember.js | f8d551721102c6b430a884bc256cf77c9edcff36.json | fix jshint warnings
A recent version of jshint has begun finding problems that were missed by earlier versions. This cleans them up. | packages/ember-htmlbars/tests/attr_nodes/sanitized_test.js | @@ -56,6 +56,7 @@ var badTags = [
];
for (var i = 0, l = badTags.length; i < l; i++) {
+ /* jshint -W083 */
(function() {
var subject = badTags[i];
@@ -118,6 +119,7 @@ for (var i = 0, l = badTags.length; i < l; i++) {
'unsafe:javascript://example.com',
'attribute is output');
... | true |
Other | emberjs | ember.js | f8d551721102c6b430a884bc256cf77c9edcff36.json | fix jshint warnings
A recent version of jshint has begun finding problems that were missed by earlier versions. This cleans them up. | packages/ember-runtime/lib/ext/rsvp.js | @@ -1,5 +1,3 @@
-/* globals RSVP:true */
-
import Ember from 'ember-metal/core';
import require, { has } from 'require';
import { assert } from 'ember-metal/debug'; | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.