@azuro-org/toolkit 0.1.6 → 0.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -13
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -49,7 +49,7 @@ type Conditions = {
|
|
|
49
49
|
aggregateOutcomesByMarkets({
|
|
50
50
|
lpAddress: game.liquidityPool.lpAddress,
|
|
51
51
|
conditions: game.conditions,
|
|
52
|
-
dictionaries, // **
|
|
52
|
+
dictionaries, // **
|
|
53
53
|
})
|
|
54
54
|
```
|
|
55
55
|
|
|
@@ -66,7 +66,7 @@ type Outcome = {
|
|
|
66
66
|
|
|
67
67
|
type OutcomesByMarkets = {
|
|
68
68
|
marketName: string
|
|
69
|
-
outcomes: Outcome[][]
|
|
69
|
+
outcomes: Outcome[][] // *
|
|
70
70
|
}[]
|
|
71
71
|
```
|
|
72
72
|
|
|
@@ -77,19 +77,18 @@ in a user-friendly way and provide more context about what the outcome represent
|
|
|
77
77
|
component of Azuro's infrastructure as they allow for standardized and consistent outcomes across all markets and events.
|
|
78
78
|
[Read more about dictionaries](https://azuro-v2-docs.surge.sh/build-own-app/dive-deeper/dictionaries).
|
|
79
79
|
|
|
80
|
+
---
|
|
81
|
+
|
|
80
82
|
You can pass additional data in outcomes if required, the helper will add it to outcomes in the result:
|
|
81
83
|
|
|
82
84
|
```graphql {11}
|
|
83
85
|
query Game($id: String!) {
|
|
84
86
|
game(id: $id) {
|
|
85
|
-
|
|
86
|
-
address
|
|
87
|
-
}
|
|
87
|
+
...
|
|
88
88
|
conditions {
|
|
89
|
-
|
|
90
|
-
coreAddress
|
|
89
|
+
...
|
|
91
90
|
outcomes {
|
|
92
|
-
|
|
91
|
+
...
|
|
93
92
|
odds
|
|
94
93
|
}
|
|
95
94
|
}
|
|
@@ -103,11 +102,7 @@ type MyOutcome = {
|
|
|
103
102
|
odds: string
|
|
104
103
|
}
|
|
105
104
|
|
|
106
|
-
aggregateOutcomesByMarkets<MyOutcome>(
|
|
107
|
-
lpAddress: game.liquidityPool.lpAddress,
|
|
108
|
-
conditions: game.conditions,
|
|
109
|
-
dictionaries, // ** check the note below
|
|
110
|
-
})
|
|
105
|
+
aggregateOutcomesByMarkets<MyOutcome>(...)
|
|
111
106
|
```
|
|
112
107
|
|
|
113
108
|
The result will be of type
|