From f7116a33f287a709e5273c064f744f6ef22b256d Mon Sep 17 00:00:00 2001 From: David Baker Date: Thu, 14 Feb 2019 15:38:11 -0700 Subject: [PATCH] Cleaning up small typos --- text/0000-handlebars-strict-mode.md | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/text/0000-handlebars-strict-mode.md b/text/0000-handlebars-strict-mode.md index eb50bc61e9..ae3e111761 100644 --- a/text/0000-handlebars-strict-mode.md +++ b/text/0000-handlebars-strict-mode.md @@ -16,7 +16,7 @@ are using today) will be referred to as "sloppy mode" in this RFC. ## Motivation Ember has been using Handlebars since it was released 7 years ago (!). Over -time, we have evloved, adapted and in some case repurposed the Handlebars +time, we have evolved, adapted and in some case repurposed the Handlebars language significantly (remember "context-shifting" `{{#each}}`?). This RFC propose to provide a "strict mode" opt-in to remedy some of Handlebars' design decisions that we have come to regret over the years, or are otherwise not a @@ -33,7 +33,7 @@ We propose the following changes: ### 1. No implicit globals -Today, Ember implicitly introduce a set of implicit globals into a template's +Today, Ember implicitly introduces a set of implicit globals into a template's scope, such as built-in helpers, components, modifiers. Apps and addons also have the ability to introduce additional implicit globals by placing files into the `app` folder or broccoli tree. It is also possible to further influence @@ -118,7 +118,7 @@ the [template imports RFC](./0000-template-imports.md)): ```hbs --- import { eq, get, hash } from '@ember/template/helpers'; -import { First, Second, Third } form './contextual-components'; +import { First, Second, Third } from './contextual-components'; --- {{#if (eq this.selected "first")}} @@ -207,7 +207,7 @@ The `precompile` function (a.k.a. [`precompileTemplate`](https://github.com/embe is responsible for taking a template string, running AST plugins, checking for errors and returning the "wire format" representation of the template. The exact details of this "wire format" is unspecified and changes from time to -time across minor Ember versions. The only guarentee is that it returns a +time across minor Ember versions. The only guarantee is that it returns a string whose content is a valid JavaScript expression. For example: @@ -282,7 +282,7 @@ For example, consider the following template: {{/let}} ``` -Here, `this.session.currentUser` is an explicit refernce to the component's +Here, `this.session.currentUser` is an explicit reference to the component's instance state, `user` is a local variable introduced by the `#let` helper, `@model` is a reference to a named argument. They all have obvious semantics. @@ -416,7 +416,7 @@ implicit globals and dynamic resolution co-exists with template imports (the primary consumer of the proposed strict mode). However, this will create a very confusing compromise and users will not get most of the benefits of having template imports in the first place. We will also lose out on the opportunity -to improve on the static guarentees in order to build better tools. Leaving +to improve on the static guarantees in order to build better tools. Leaving around implicit globals also has the [issues](https://github.com/emberjs/rfcs/blob/master/text/0432-contextual-helpers.md#relationship-with-globals) discussed in the contextual helpers RFC. @@ -437,7 +437,7 @@ discussed in the contextual helpers RFC. 2. Instead of proposing a standalone strict mode, we could just bundle these semantics into the templates imports proposal. - That would make it a very long anc complex RFC. In addition, other build + That would make it a very long and complex RFC. In addition, other build tools like [ember-cli-htmlbars-inline-precompile](https://github.com/ember-cli/ember-cli-htmlbars-inline-precompile) will not be able to adopt the same semantics. @@ -450,7 +450,7 @@ discussed in the contextual helpers RFC. We intend to move to an "attributes syntax always mean attributes" (and use modifiers for the rare cases of setting properties). We briefly considered - groupping that change into the strict mode opt-in, but ultimately decided it + grouping that change into the strict mode opt-in, but ultimately decided it would be too confusing for strict mode to include such a change. It's better to deprecate the feature and make this an app-wide setting. @@ -458,7 +458,7 @@ discussed in the contextual helpers RFC. Similarly, there are some not ideal semantics issues with `(action ...)` around how the function's `this` is bound. We similarly considered fixing it - in strict mode but ultimately decided it wouldn't be appropiate. + in strict mode but ultimately decided it wouldn't be appropriate. ## Unresolved questions