Skip to content

Commit 1fa61a8

Browse files
authored
Update highlighting for onCreate method for clarity (#1450)
1 parent c52c390 commit 1fa61a8

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

versioned_docs/version-7.x/getting-started.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -99,12 +99,14 @@ import com.swmansion.rnscreens.fragment.restoration.RNScreensFragmentFactory
9999

100100
class MainActivity: ReactActivity() {
101101
// ...
102+
103+
// highlight-start
102104
override fun onCreate(savedInstanceState: Bundle?) {
103-
// highlight-start
104105
supportFragmentManager.fragmentFactory = RNScreensFragmentFactory()
105106
super.onCreate(savedInstanceState)
106-
// highlight-end
107107
}
108+
// highlight-end
109+
108110
// ...
109111
}
110112
```
@@ -122,13 +124,15 @@ import com.swmansion.rnscreens.fragment.restoration.RNScreensFragmentFactory;
122124

123125
public class MainActivity extends ReactActivity {
124126
// ...
127+
128+
// highlight-start
125129
@Override
126130
protected void onCreate(Bundle savedInstanceState) {
127-
// highlight-start
128131
getSupportFragmentManager().setFragmentFactory(new RNScreensFragmentFactory());
129132
super.onCreate(savedInstanceState);
130-
// highlight-end
131133
}
134+
// highlight-end
135+
132136
// ...
133137
}
134138
```

0 commit comments

Comments
 (0)