Skip to content

Commit fe58756

Browse files
committed
Fix typos
This was found by running an IntellijIDE code inspection for proofreading.
1 parent b0f1a62 commit fe58756

File tree

9 files changed

+11
-11
lines changed

9 files changed

+11
-11
lines changed

docs/compiler-api.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,7 @@ scanner.accept(ast);
291291

292292
The current node's ancestors will be maintained in the `parents` array, with the most recent parent listed first.
293293

294-
The visitor may also be configured to operate in mutation mode by setting the `mutating` field to true. When in this mode, handler methods may return any valid AST node and it will replace the one they are currently operating on. Returning `false` will remove the given value (if valid) and returning `undefined` will leave the node in tact. This return structure only apply to mutation mode and non-mutation mode visitors are free to return whatever values they wish.
294+
The visitor may also be configured to operate in mutation mode by setting the `mutating` field to true. When in this mode, handler methods may return any valid AST node and it will replace the one they are currently operating on. Returning `false` will remove the given value (if valid) and returning `undefined` will leave the node intact. This return structure only apply to mutation mode and non-mutation mode visitors are free to return whatever values they wish.
295295

296296
Implementors that may need to support mutation mode are encouraged to utilize the `acceptKey`, `acceptRequired` and `acceptArray` helpers which provide the conditional overwrite behavior as well as implement sanity checks where pertinent.
297297

docs/decorators-api.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
**Decorators are deprecated, please join the discussion at [#1574](https://github.com/wycats/handlebars.js/issues/1574) to see what we can do about it.**
44

5-
Decorators allow for blocks to be annotated with metadata or wrapped in functionality prior to execution of the block. This may be used to communicate with the containing helper or to setup a particular state in the system prior to running the block.
5+
Decorators allow for blocks to be annotated with metadata or wrapped in functionality prior to execution of the block. This may be used to communicate with the containing helper or to set up a particular state in the system prior to running the block.
66

77
Decorators are registered through similar methods as helpers, `registerDecorators` and `unregisterDecorators`. These can then be referenced via the friendly name in the template using the `{{* decorator}}` and `{{#* decorator}}{/decorator}}` syntaxes. These syntaxes are derivatives of the normal mustache syntax and as such have all of the same argument and whitespace behaviors.
88

lib/handlebars/compiler/code-gen.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ let SourceNode;
66
try {
77
/* istanbul ignore next */
88
if (typeof define !== 'function' || !define.amd) {
9-
// We don't support this in AMD environments. For these environments, we asusme that
9+
// We don't support this in AMD environments. For these environments, we assume that
1010
// they are running on the browser and thus have no need for the source-map library.
1111
let SourceMap = require('source-map');
1212
SourceNode = SourceMap.SourceNode;

lib/handlebars/helpers/each.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ export default function(instance) {
6060
Object.keys(context).forEach(key => {
6161
// We're running the iterations one step out of sync so we can detect
6262
// the last iteration without have to scan the object twice and create
63-
// an itermediate keys array.
63+
// an intermediate keys array.
6464
if (priorKey !== undefined) {
6565
execIteration(priorKey, i - 1);
6666
}

lib/handlebars/helpers/if.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export default function(instance) {
1111
}
1212

1313
// Default behavior is to render the positive path if the value is truthy and not empty.
14-
// The `includeZero` option may be set to treat the condtional as purely not empty based on the
14+
// The `includeZero` option may be set to treat the conditional as purely not empty based on the
1515
// behavior of isEmpty. Effectively this determines if 0 is handled by the positive path or negative.
1616
if ((!options.hash.includeZero && !conditional) || isEmpty(conditional)) {
1717
return options.inverse(this);

lib/handlebars/internal/proto-access.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,11 +47,11 @@ function checkWhiteList(protoAccessControlForType, propertyName) {
4747
if (protoAccessControlForType.defaultValue !== undefined) {
4848
return protoAccessControlForType.defaultValue;
4949
}
50-
logUnexpecedPropertyAccessOnce(propertyName);
50+
logUnexpectedPropertyAccessOnce(propertyName);
5151
return false;
5252
}
5353

54-
function logUnexpecedPropertyAccessOnce(propertyName) {
54+
function logUnexpectedPropertyAccessOnce(propertyName) {
5555
if (loggedProperties[propertyName] !== true) {
5656
loggedProperties[propertyName] = true;
5757
logger.log(

spec/data.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ describe('data', function() {
217217
})
218218
.withInput({ exclaim: true, zomg: 'planet' })
219219
.withRuntimeOptions({ data: { adjective: 'happy' } })
220-
.withMessage('Overriden data output by helper')
220+
.withMessage('Overridden data output by helper')
221221
.toCompileTo('sad world?');
222222
});
223223

@@ -232,7 +232,7 @@ describe('data', function() {
232232
})
233233
.withInput({ exclaim: true, zomg: 'world' })
234234
.withRuntimeOptions({ data: { adjective: 'happy' } })
235-
.withMessage('Overriden data output by helper')
235+
.withMessage('Overridden data output by helper')
236236
.toCompileTo('sad world?');
237237
});
238238

spec/utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ describe('utils', function() {
2222
});
2323

2424
describe('#escapeExpression', function() {
25-
it('shouhld escape html', function() {
25+
it('should escape html', function() {
2626
equals(
2727
Handlebars.Utils.escapeExpression('foo<&"\'>'),
2828
'foo&lt;&amp;&quot;&#x27;&gt;'

spec/vendor/require.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1488,7 +1488,7 @@ var requirejs, require, define;
14881488
/**
14891489
* Called to enable a module if it is still in the registry
14901490
* awaiting enablement. A second arg, parent, the parent module,
1491-
* is passed in for context, when this method is overriden by
1491+
* is passed in for context, when this method is overridden by
14921492
* the optimizer. Not shown here to keep code compact.
14931493
*/
14941494
enable: function (depMap) {

0 commit comments

Comments
 (0)