Skip to content

Commit

Permalink
indentation fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
hborawski committed Jan 30, 2024
1 parent 2d580e5 commit 0ad9807
Show file tree
Hide file tree
Showing 7 changed files with 37 additions and 15 deletions.
11 changes: 10 additions & 1 deletion docs/site/pages/plugins/beacon.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,15 @@ This will add additional React Context to the running player for the producers f
</react>
<ios>

### CocoaPods
Add the subspec to your `Podfile`

```ruby
pod 'PlayerUI/BeaconPlugin'
```

### Swift Usage

To receive Beacon events from Player in iOS, add the `BeaconPlugin` to your plugin array:

```swift
Expand All @@ -104,7 +113,7 @@ var body: some View {
flow: flow,
plugins: [
BeaconPlugin<DefaultBeacon> { (beacon: DefaultBeacon) in
// Process beacon into the format you need for Segment/Trinity and send it on
// Process beacon into the format you need for your analytics platform
}
]
)
Expand Down
3 changes: 2 additions & 1 deletion docs/site/pages/plugins/check-path.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ This will automatically create the underlying _core_ version of the `CheckPathPl
</react>

<ios>

### CocoaPods

Add the subspec to your `Podfile`
Expand All @@ -82,7 +83,7 @@ var body: some View {
SwiftUIPlayer(
flow: flow,
plugins: [
SwiftUICheckPathPlugin()
SwiftUICheckPathPlugin()
],
result: $resultBinding
)
Expand Down
2 changes: 1 addition & 1 deletion docs/site/pages/plugins/common-expressions.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ var body: some View {
SwiftUIPlayer(
flow: flow,
plugins: [
CommonExpressionsPlugin()
CommonExpressionsPlugin()
],
result: $resultBinding
)
Expand Down
2 changes: 1 addition & 1 deletion docs/site/pages/plugins/common-types.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ var body: some View {
SwiftUIPlayer(
flow: flow,
plugins: [
CommonTypesPlugin()
CommonTypesPlugin()
],
result: $resultBinding
)
Expand Down
2 changes: 1 addition & 1 deletion docs/site/pages/plugins/computed-properties.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ var body: some View {
SwiftUIPlayer(
flow: flow,
plugins: [
ComputedPropertiesPlugin()
ComputedPropertiesPlugin()
],
result: $resultBinding
)
Expand Down
21 changes: 13 additions & 8 deletions docs/site/pages/plugins/console-logger.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -34,23 +34,28 @@ consoleLogger.setSeverity('warn');
</core>
<ios>

Add the subspec:
### CocoaPods
Add the subspec to your `Podfile`

```ruby
pod 'PlayerUI/PrintLoggerPlugin'
```

Construct the plugin:
### Swift Usage

```swift
SwiftUIPlayer(
flow: flow,
plugins: [PrintLoggerPlugin()],
result: $result
)
var body: some View {
SwiftUIPlayer(
flow: flow,
plugins: [
PrintLoggerPlugin()
],
result: $resultBinding
)
}
```

To change the severity:
To change the severity, supply it as an argument to the constructor:
```swift
PrintLoggerPlugin(level: .warn)
```
Expand Down
11 changes: 9 additions & 2 deletions docs/site/pages/plugins/expression.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,14 @@ Any calls to `myCustomFunction()` within the flow will utilize the newly registe
</core>
<ios>

### Use
### CocoaPods
Add the subspec to your `Podfile`

```ruby
pod 'PlayerUI/ExpressionPlugin'
```

### Swift Usage

The ExpressionPlugin lets you register custom expressions to run native code:

Expand All @@ -71,7 +78,7 @@ let expressionPlugin = ExpressionPlugin(expressions: [
}
])
```
### Arguments
#### Arguments

Arguments can be passed to custom expressions, and your handler receives the arguments as an array of Any:

Expand Down

0 comments on commit 0ad9807

Please sign in to comment.