---
title: resetDatastore()
framework: tipkit
role: symbol
role_heading: Type Method
path: tipkit/tips/resetdatastore()
---

# resetDatastore()

Resets the tips’ datastore to the initial state for re-testing tip display rules and eligibility.

## Declaration

```swift
static func resetDatastore() throws
```

## Overview

Overview Must be called before configure(_:). This function can also be called with the launch argument -com.apple.TipKit.ResetDatastore 1. important: This function removes the existing tip, event, and parameter records from your app’s TipKit datastore and will cause previously dismissed tips to become re-eligible for display. It is primarily designed for testing your app’s first launch experience. import SwiftUI import TipKit

@main struct LandmarkTips: App {     var body: some Scene {         WindowGroup {             ContentView()         }     }

init() {         setupTips()     }

// Configure tips in the app.     func setupTips() {         do {             #if DEBUG             try Tips.resetDatastore()             #endif

try Tips.configure()         }         catch {             print("Error initializing TipKit \(error.localizedDescription)")         }     } }

## See Also

### Testing

- [showAllTipsForTesting()](tipkit/tips/showalltipsfortesting().md)
- [showTipsForTesting(_:)](tipkit/tips/showtipsfortesting(_:).md)
- [hideAllTipsForTesting()](tipkit/tips/hidealltipsfortesting().md)
- [hideTipsForTesting(_:)](tipkit/tips/hidetipsfortesting(_:).md)
