Skip to content

Commit f7def4e

Browse files
gabriel-logancoado
authored andcommitted
docs: update turbo-native-modules-android.md (react#4665)
1 parent 161f708 commit f7def4e

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

website/versioned_docs/version-0.80/turbo-native-modules-android.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,12 @@ public class NativeLocalStorageModule extends NativeLocalStorageSpec {
5353
SharedPreferences sharedPref = getReactApplicationContext().getSharedPreferences("my_prefs", Context.MODE_PRIVATE);
5454
sharedPref.edit().remove(key).apply();
5555
}
56+
57+
@Override
58+
public void clear() {
59+
SharedPreferences sharedPref = getReactApplicationContext().getSharedPreferences("my_prefs", Context.MODE_PRIVATE);
60+
sharedPref.edit().clear().apply();
61+
}
5662
}
5763
```
5864

0 commit comments

Comments
 (0)