diff --git a/_source/handbook/01_introduction.md b/_source/handbook/01_introduction.md index 7a59c1d..5ce93b5 100644 --- a/_source/handbook/01_introduction.md +++ b/_source/handbook/01_introduction.md @@ -6,8 +6,8 @@ description: "Strada is a set of three libraries that coordinate across the web, # Introduction -You can build [Turbo Native](https://turbo.hotwired.dev/handbook/native) apps to enjoy the best of the web alongside the best of native apps and fully native screens. But, there's a major limitation: there's no way for the native app to know what's happening within the `WebView` and adapt to the content that its displaying. +You can build [Turbo Native](https://turbo.hotwired.dev/handbook/native) apps to enjoy the best of the web alongside the best of native apps and fully native screens. But, there's a major limitation: there's no way for the native app to know what's happening within the `WebView` and adapt to the content that it's displaying. Additionally, it'd be great for some web features to break out of the `WebView` container and drive native features — whether it's displaying native buttons in the top app bar, displaying native menu sheets, or calling native platform APIs. Strada enables you to do all of this and gives you the flexibility to build components that are specific to your app's needs. -Strada acts a "bridge" between your web code and your native app code, letting your web app and native app communicate through a component-based framework. It abstracts away the complexity of communicating with javascript code in a `WebView` and native code in your app. +Strada acts a "bridge" between your web code and your native app code, letting your web app and native app communicate through a component-based framework. It abstracts away the complexity of communicating with JavaScript code in a `WebView` and native code in your app. diff --git a/_source/handbook/02_how_it_works.md b/_source/handbook/02_how_it_works.md index 138b1af..16d7b97 100644 --- a/_source/handbook/02_how_it_works.md +++ b/_source/handbook/02_how_it_works.md @@ -9,7 +9,7 @@ Strada uses a component-based approach to create a bidirectional communication c Web components "send" messages to their corresponding native components. Native components "receive" the messages to build and display native controls, populating them with `data` supplied in the messages. When native components want to inform their corresponding web components of a user action or state change, the native components "reply" to the originally received messages. Web components "receive" the replies and invoke a callback to update the web component based on the reply message `data`. -Strada leverages [Stimulus](https://stimulus.hotwired.dev) to bring you the same power to your web components. In fact, the core `BridgeComponent` class is an extension of a Stimulus `Controller`, so you should be familiar with Stimulus before building Strada components. +Strada leverages [Stimulus](https://stimulus.hotwired.dev) to bring the same power to your web components. In fact, the core `BridgeComponent` class is an extension of a Stimulus `Controller`, so you should be familiar with Stimulus before building Strada components. ## Demo Examples @@ -56,7 +56,7 @@ Let's update the form with bridge attributes and create a new web component, lev ``` -Now, we'll create a new `"form"` component in a similar way you create Stimulus controllers, but extending the `BridgeComponent` class: +Now, we'll create a new `"form"` component. This is similar to the way you create Stimulus controllers, but extending the `BridgeComponent` class: ```javascript // bridge/form_controller.js @@ -70,7 +70,7 @@ export default class extends BridgeComponent { } ``` -The basic `"form"` component is now created we can send a `message` to a corresponding native `"form"` component in the native app. We'll send the submit button's title as JSON `data` in the message, so the native component can set the native button's title with the `submitTitle`. +With the basic `"form"` component created, we can now send a `message` to a corresponding native `"form"` component. We'll send the submit button's title as JSON `data` in the message, so the native component can set the native button's title with the `submitTitle`. ```javascript // bridge/form_controller.js @@ -91,9 +91,9 @@ export default class extends BridgeComponent { } ``` -Notice the 3rd parameter when calling `send()`. It's a callback function that will get called when the native component replies back to the `"connect"` message. The submit button in the `