Skip to content

Commit c4911cb

Browse files
authored
Update README.md
1 parent 003a0a8 commit c4911cb

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ class ViewController: UIViewController {
1313
}
1414
```
1515

16-
DSBridge-Swift does not rely on Objective-C runtime. Thus you can declare your interface with pure Swift types, with the bundled macro `Exposed`:
16+
DSBridge-Swift does not rely on Objective-C runtime. Thus you can declare your interface with pure Swift types:
1717
```swift
1818

1919
import Foundation
@@ -27,9 +27,9 @@ class MyInterface {
2727
func localMethod()
2828
}
2929
```
30-
Add `unexposed` annotation to any function you don't want to expose, .
30+
Mark your interface `@Exposed` and that's it. Add `@unexposed` annotation to any function you don't want to expose.
3131

32-
You can also declare your it with a struct. Or, even further, an enum!
32+
If you don't need to declare it as a class, why not use a struct? Or, even further, an enum!
3333
```swift
3434
@Exposed
3535
enum EnumInterface {
@@ -77,7 +77,7 @@ bridge.call('asyncStyledFunction', function(v) { console.log(v) });
7777
// ""
7878
// Async response
7979
```
80-
As you can see, there is a immediate empty return. The response sent by us is printed by the `function`.
80+
As you can see, there is a empty string returned. The response we sent in the interface is printed by the `function`.
8181

8282
OK, we send async response with the completion in its first parameter. What does the second parameter, the `Bool` do then?
8383

0 commit comments

Comments
 (0)