Skip to content

Commit 66c884e

Browse files
committed
Adding quick-fixes for typo/wording improvements for the Getting Started Guide for @leggeter to review
#7 (View the code js file path reference correction) #9/#10 - Updating all getting-started screenshots which had the 'Messages' widget on workbench pages on the left as these have been removed from the template #11 Fixing typo for first para of Add Two-Way Data Binding #12 Fixing function reference 'enterPressed' -> 'keyPressed' #13 Changing 'to see if it's the *Enter/Return*' -> 'to see if it was the *Enter/Return* key' #14 This was resolved when the 'Run the Test' section was reworked after adding --no-browser flag support #28 Typo fix: 'updated it to look as follows' -> 'update it to look as follows'
1 parent 18a183e commit 66c884e

File tree

4 files changed

+4
-4
lines changed

4 files changed

+4
-4
lines changed

docs/use/getting_started.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ This creates a `todoinput` directory within `unzip_location/apps/brjs-todo/todo-
112112

113113
### View the Code
114114

115-
Within `apps/todo-bladeset/blades/todoinput/src/bjrstodo/todo/todoinput/src` you'll find an `ExamplePresentationModel.js` file.
115+
Within `apps/brjs-todo/todo-bladeset/blades/todoinput/src/bjrstodo/todo/todoinput/src` you'll find an `ExamplePresentationModel.js` file.
116116

117117
<div class="alert alert-info github">
118118
<p>Yeah, this folder structure is crazy! We're working on a <a href="https://github.com/BladeRunnerJS/brjs/issues/19">simplified directory structure</a></p>
@@ -169,7 +169,7 @@ If you click the `Log me` button the `buttonClicked` function is called and `but
169169

170170
### Add Two-Way Data Binding
171171

172-
Next, let's edit the Blade to display in `<input>` element with a two-way binding between the View and View Model.
172+
Next, let's edit the Blade to display an `<input>` element with a two-way binding between the View and View Model.
173173

174174
To do this we first need to update `ExamplePresentationModel.js` to handle the fact the view contains an input element. We do this using a `Field` object initialized with an empty string, instead of 'Hello World!'. We can also update the `message` instance variable to be called something more relevant: `todoText`.
175175

@@ -203,7 +203,7 @@ Finally, instead of having to click a button we should handle the *Enter/Return*
203203

204204
} )();
205205

206-
We also update `view.html` to contain an `input` element where the element's `value` property is bound to the newly named `todoText` value. We want instant two-way binding so we also need to add `valueUpdate:'afterkeydown'` to the `data-bind` attribute. And we also want to call the newly named `enterPressed` function when a key is pressed in the input to check to see if it's the *Enter/Return*. We do this by adding `event: { keypress: keyPressed }` to the `data-bind` attribute. Finally, update the `class` attribute to indicate the input is a `todo-input`, add a `placeholder` attribute and remove the unused `<button>` element:
206+
We also update `view.html` to contain an `input` element where the element's `value` property is bound to the newly named `todoText` value. We want instant two-way binding so we also need to add `valueUpdate:'afterkeydown'` to the `data-bind` attribute. And we also want to call the newly named `keyPressed` function when a key is pressed in the input to check to see if it was the *Enter/Return* key. We do this by adding `event: { keypress: keyPressed }` to the `data-bind` attribute. Finally, update the `class` attribute to indicate the input is a `todo-input`, add a `placeholder` attribute and remove the unused `<button>` element:
207207

208208
<div id="brjstodo.todo.todoinput.view-template">
209209
<div>
@@ -704,7 +704,7 @@ Both the `todoinput` and `todoitems` Blades have the functionality that we're lo
704704

705705
## Adding the Blades to an Aspect
706706

707-
In order to add the Blades to the default aspect we need to first update the aspect HTML to provide some basic structure. Open up `brjs-todo/default-aspect/index.html` and updated it to look as follows:
707+
In order to add the Blades to the default aspect we need to first update the aspect HTML to provide some basic structure. Open up `brjs-todo/default-aspect/index.html` and update it to look as follows:
708708

709709
<!DOCTYPE html>
710710
<html>
22.5 KB
Loading
22.7 KB
Loading

docs/use/img/todo-items-workbench.png

19.8 KB
Loading

0 commit comments

Comments
 (0)