Skip to content
Back to search

boutique

MarketplaceWorks with Claude CodeGitHub

Boutique skills for Swift persistence workflows.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today

Check it deeper on your machine

It has changed since its scan on 11 Nov 2026.

As a Claude Code plugin, install it and then ask Claude Code:

/plugin marketplace add keithmackay/mackayi/plugin install scanskillsafety@mackayiDo a deep scan of https://github.com/mergesort/Boutique with scanskillsafety

Or from a terminal, clone it and run it:

git clone https://github.com/keithmackay/scanskillsafety-skill ~/.claude/skills/scanskillsafetynode ~/.claude/skills/scanskillsafety/cli.cjs --deep 'https://github.com/mergesort/Boutique'

It checks the exact commit: every file, its packages against OSV (api.osv.dev), how it compares with this page's scan (findsafeskills.com receives the repository's address), and, if you agree, Claude reading every file with your own Claude subscription. It never runs the code.

Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/mergesort--boutique/badge.svg)](/listings/mergesort--boutique)

HTML

<a href="/listings/mergesort--boutique"><img src="/api/listings/mergesort--boutique/badge.svg" alt="findsafeskills safety rating" /></a>

Install

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Boutique only has one concept you need to understand. When you save data to the ``Store`` your data will be persisted automatically for you and exposed as a regular Swift array. The ``@StoredValue`` and ``@SecurelyStoredValue`` property wrappers work the same way, but instead of an array they work with singular Swift values. You'll never have to think about databases, everything in your app is a regular Swift array or value using your app's models, with straightforward code that looks like any other app.

You may be familiar with the ``Store`` from [Redux](https://redux.js.org/) or [The Composable Architecture](https://github.com/pointfreeco/swift-composable-architecture), but unlike those frameworks you won't need to worry about adding Actions or Reducers. With this ``Store`` implementation all your data is persisted for you automatically, no additional code required. This allows you to build realtime updating apps with full offline support in an incredibly simple and straightforward manner.

You can read a high level overview of Boutique below, but Boutique is also fully documented [here](https://mergesort.github.io/Boutique/documentation/boutique).

---

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

.claude-plugin/marketplace.json · Manifest · 13 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. {
  2. "name": "boutique",
  3. "owner": {
  4. "name": "Joe Fabisevich"
  5. },
  6. "description": "Boutique skills for Swift persistence workflows.",
  7. "plugins": [
  8. {
  9. "name": "boutique",
  10. "source": "./plugins/boutique"
  11. }
  12. ]
  13. }
README.md · README · 400 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. ![Boutique Logo](Images/logo.jpg)
  2. ### A simple but surprisingly fancy data store and so much more
  3. >*"I ripped out Core Data, this is the way it should work"*
  4. — [Josh Holtz](https://github.com/joshdholtz)
  5. >*"Boutique is ridiculously easy to implement and makes persistence a breeze. It's become my first addition to every project I start.*
  6. — [Tyler Hillsman](https://github.com/thillsman)
  7. >*"Boutique has become invaluable, I use it in every side project now. Not having to care about persistence is great and the cost of getting started is practically zero."*
  8. — [Romain Pouclet](https://github.com/palleas)
  9. If you find Boutique valuable I would really appreciate it if you would consider helping [sponsor my open source work](https://github.com/sponsors/mergesort), so I can continue to work on projects like Boutique to help developers like yourself.
  10. Table of Contents
  11. - [Intro](#intro)
  12. - [Getting Started](#getting-started)
  13. - [Store](#store)
  14. - [The Magic Of @Stored](#the-magic-of-stored)
  15. - [@StoredValue & @SecurelyStoredValue](#storedvalue--securelystoredvalue)
  16. - [Documentation](#documentation)
  17. - [Coding Agent Plugins](#coding-agent-plugins)
  18. - [Further Exploration](#further-exploration)
  19. - [Coding Agent Plugins](#coding-agent-plugins)
  20. - [Feedback & Contribution](#feedback)
  21. ---
  22. ### Intro
  23. Boutique is a simple but powerful persistence library, a small set of property wrappers and types that enable building incredibly simple state-driven apps for SwiftUI, UIKit, and AppKit. With its dual-layered memory + disk caching architecture, Boutique provides a way to build apps that update in real time with full offline storage in only a few lines of code — using an incredibly simple API.
  24. - Boutique is used in hundreds of apps, and I thoroughly test every API in my app [Plinky](https://plinky.app). (Which I highly recommend [downloading](https://plinky.app/download) and maybe even subscribing to. 😉)
  25. - Boutique is built atop [Bodega](https://github.com/mergesort/Bodega), and you can find a demo app built atop the Model View Controller Store architecture in this [repo](https://github.com/mergesort/Boutique/tree/main/Demo) which shows you how to make an offline-ready SwiftUI app in only a few lines of code. You can read more about the thinking behind the architecture in this blog post exploring the [MVCS architecture](https://build.ms/2022/06/22/model-view-controller-store).
  26. ---
  27. ### Getting Started
  28. Boutique only has one concept you need to understand. When you save data to the ``Store`` your data will be persisted automatically for you and exposed as a regular Swift array. The ``@StoredValue`` and ``@SecurelyStoredValue`` property wrappers work the same way, but instead of an array they work with singular Swift values. You'll never have to think about databases, everything in your app is a regular Swift array or value using your app's models, with straightforward code that looks like any other app.
  29. You may be familiar with the ``Store`` from [Redux](https://redux.js.org/) or [The Composable Architecture](https://github.com/pointfreeco/swift-composable-architecture), but unlike those frameworks you won't need to worry about adding Actions or Reducers. With this ``Store`` implementation all your data is persisted for you automatically, no additional code required. This allows you to build realtime updating apps with full offline support in an incredibly simple and straightforward manner.
  30. You can read a high level overview of Boutique below, but Boutique is also fully documented [here](https://mergesort.github.io/Boutique/documentation/boutique).
  31. ---
  32. ### Store
  33. We'll go through a high level overview of the `Store` below, but the `Store` is fully documented with context, use cases, and examples [here](https://mergesort.github.io/Boutique/documentation/boutique/using-stores/).
  34. The entire surface area of the API for achieving full offline support and realtime model updates across your entire app is three methods, `.insert()`, `.remove()`, and `.removeAll()`.
  35. ```swift
  36. // Create a Store ¹
  37. let store = Store<Animal>(
  38. storage: SQLiteStorageEngine.default(appendingPath: "Animals"),
  39. cacheIdentifier: \.id
  40. )
  41. // Insert an item into the Store ²
  42. let redPanda = Animal(id: "red_panda")
  43. try await store.insert(redPanda)
  44. // Remove an animal from the Store
  45. try await store.remove(redPanda)
  46. // Insert two more animals to the Store
  47. let dog = Animal(id: "dog")
  48. let cat = Animal(id: "cat")
  49. try await store.insert([dog, cat])
  50. // You can read items directly
  51. print(store.items) // Prints [dog, cat]
  52. // You also don't have to worry about maintaining uniqueness, the Store handles uniqueness for you
  53. let secondDog = Animal(id: "dog")
  54. try await store.insert(secondDog)
  55. print(store.items) // Prints [dog, cat]
  56. // Clear your store by removing all the items at once.
  57. store.removeAll()
  58. print(store.items) // Prints []
  59. // You can even chain commands together
  60. try await store
  61. .insert(dog)
  62. .insert(cat)
  63. .run()
  64. print(store.items) // Prints [dog, cat]
  65. // This is a good way to clear stale cached data
  66. try await store
  67. .removeAll()
  68. .insert(redPanda)
  69. .run()
  70. print(store.items) // Prints [redPanda]
  71. ```
  72. And if you're building a SwiftUI app you don't have to change a thing, Boutique was made for and with SwiftUI in mind. (But works well in UIKit and AppKit of course. 😉)
  73. ```swift
  74. // Since @Store, @StoredValue, and @SecurelyStoredValue are `@Observable`, you can subscribe
  75. // to changes in realtime using any of Swift's built-in observability mechanisms.
  76. .onChange(of: store.items) {
  77. self.items = self.items.sorted(by: { $0.createdAt > $1.createdAt})
  78. })
  79. ```
  80. ```swift
  81. // You can also use Boutique's Granular Events Tracking API to be notified of individual changes.
  82. func monitorNotesStoreEvents() async {
  83. for await event in self.notesController.$notes.events {
  84. switch event.operation {
  85. case .initialized:
  86. print("[Store Event: initial] Our Notes Store has initialized")
  87. case .loaded:
  88. print("[Store Event: loaded] Our Notes Store has loaded with notes", event.notes.map(\.text))
  89. case .insert:
  90. print("[Store Event: insert] Our Notes Store inserted notes", event.notes.map(\.text))
  91. case .remove:
  92. print("[Store Event: remove] Our Notes Store removed notes", event.notes.map(\.text))
  93. }
  94. }
  95. }
  96. ```
  97. ---
  98. ¹ You can have as many or as few Stores as you'd like. It may be a good strategy to have one Store for all of the notes you download in your app, but you may also want to have one Store per model-type you'd like to cache. You can even create separate stores for tests, Boutique isn't prescriptive and the choice for how you'd like to model your data is yours. You'll also notice, that's a concept from Bodega which you can read about in Bodega's [StorageEngine documentation](https://mergesort.github.io/Bodega/documentation/bodega/using-storageengines).
  99. ² Under the hood the Store is doing the work of saving all changes to disk when you add or remove items.
  100. > **Warning** Storing binary blobs (such as images or Data) in Boutique is technically supported, but not recommended. The reason not to store images in Boutique is that storing images in Boutique's can balloon up the in-memory store, and your app's memory as a result. For similar reasons as it's not recommended to store images or binary blobs in a database, it's not recommended to store images or binary blobs in Boutique. Bodega provides a good solution for this problem, which you can read about in [this tutorial](https://mergesort.github.io/Bodega/documentation/bodega/building-an-image-cache/).
  101. ---
  102. ### The Magic of @Stored
  103. We'll go through a high level overview of the `@Stored` property wrapper below, but `@Stored` is fully documented with context, use cases, and examples [here](https://mergesort.github.io/Boutique/documentation/boutique/the-@stored-family-of-property-wrappers/).
  104. That was easy, but I want to show you something that makes Boutique feel downright magical. The `Store` is a simple way to gain the benefits of offline storage and realtime updates, but by using the `@Stored` property wrapper we can cache any property in-memory and on disk with just one line of code.
  105. ```swift
  106. extension Store where Item == Note {
  107. // Initialize a Store to save our notes into
  108. static let notesStore = Store<Note>(
  109. storage: SQLiteStorageEngine.default(appendingPath: "Notes")
  110. )
  111. }
  112. @Observable
  113. final class NotesController {
  114. /// Creates an @Stored property to handle an in-memory and on-disk cache of notes. ³
  115. @Stored(in: .notesStore) var notes
  116. /// Fetches `Notes` from the API, providing the user with a red panda note if the request succeeds.
  117. func fetchNotes() async throws -> Note {
  118. // Hit the API that provides you a random image's metadata
  119. let noteURL = URL(string: "https://notes.redpanda.club/random/json")!
  120. let randomNoteRequest = URLRequest(url: noteURL)
  121. let (noteResponse, _) = try await URLSession.shared.data(for: randomNoteRequest)
  122. return Note(createdAt: .now, url: noteResponse.url, text: noteResponse.text)
  123. }
  124. /// Saves an note to the `Store` in memory and on disk.
  125. func saveNote(note: Note) async throws {
  126. try await self.$notes.insert(note)
  127. }
  128. /// Removes one note from the `Store` in memory and on disk.
  129. func removeNote(note: Note) async throws {
  130. try await self.$notes.remove(note)
  131. }
  132. /// Removes all of the notes from the `Store` in memory and on disk.
  133. func clearAllNotes() async throws {
  134. try await self.$notes.removeAll()
  135. }
  136. }
  137. ```
  138. That's it, that's really it. This technique scales very well, and sharing this data across many views is exactly how Boutique scales from simple to complex apps without adding API complexity. It's hard to believe that now your app can update its state in real time with full offline storage thanks to only one line of code. `@Stored(in: .notesStore) var notes`
  139. ---
  140. ³ (If you'd prefer to decouple the store from your view model, controller, or manager object, you can inject stores into the object like this.)
  141. ```swift
  142. @Observable
  143. final class NotesController {
  144. @ObservationIgnored
  145. @Stored var notes: [Note]
  146. init(store: Store<Note>) {
  147. self._notes = Stored(in: store)
  148. }
  149. }
  150. ```
  151. ### StoredValue & SecurelyStoredValue
  152. We'll go through a high level overview of the `@StoredValue` and `@SecurelyStoredValue` property wrappers below, but they're fully documented with context, use cases, and examples [here](https://mergesort.github.io/Boutique/documentation/boutique/the-@stored-family-of-property-wrappers/).
  153. The `Store` and `@Stored` were created to store an array of data because most data apps render comes in the form of an array. But occasionally we need to store an individual value, that's where `@StoredValue` and `@SecurelyStoredValue` come in handy.
  154. Whether you need to save an important piece of information for the next time your app is launched, stored an auth token in the keychain, or you want to change how an app looks based on a user's settings, those app configurations are individual values that you'll want to persist.
  155. Often times people will choose to store individual items like that in `UserDefaults`. If you've used `@AppStorage` then `@StoredValue` will feel right at home, it has a very similar API with some additional features. A `@StoredValue` will end up being stored in `UserDefaults`, but it also exposes a `publisher` so you can easily subscribe to changes.
  156. ```swift
  157. // Setup a `@StoredValue has the same API.
  158. @StoredValue(key: "hasHapticsEnabled")
  159. var hasHapticsEnabled = false
  160. // You can also store nil values
  161. @StoredValue(key: "lastOpenedDate")
  162. var lastOpenedDate: Date? = nil
  163. // Enums work as well, as long as it conforms to `Codable` and `Equatable`.
  164. @StoredValue(key: "currentTheme")
  165. var currentlySelectedTheme = .light
  166. // Complex objects work as well
  167. struct UserPreferences: Codable, Equatable {
  168. var hasHapticsEnabled: Bool
  169. var prefersDarkMode: Bool
  170. var prefersWideScreen: Bool
  171. var spatialAudioEnabled: Bool
  172. }
  173. @StoredValue(key: "userPreferences")
  174. var preferences = UserPreferences()
  175. // Set the lastOpenedDate to now
  176. $lastOpenedDate.set(.now)
  177. // currentlySelected is now .dark
  178. $currentlySelectedTheme.set(.dark)
  179. // StoredValues that are backed by a boolean also have a toggle() function
  180. $hasHapticsEnabled.toggle()
  181. ```
  182. The `@SecurelyStoredValue` property wrapper can do everything a `@StoredValue` does, but instead of storing values in `UserDefaults` a `@SecurelyStoredValue` will persist items in the system's Keychain. This is perfect for storing sensitive values such as passwords or auth tokens, which you would not want to store in `UserDefaults`.
  183. ### A Note on `@MainActor`
  184. You may have noticed that the `Store`, `StoredValue`, and `SecurelyStoredValue` are bound to the `@MainActor`. This may seem like it could cause performance issues, but I'm confident that is not the case Boutique or apps using Boutique. For additional details check out the documentation [here](https://mergesort.github.io/Boutique/documentation/boutique/using-stores/#Your-Favorite-Actor-%F0%9F%91%A9%F0%9F%8F%BB%E2%80%8D%F0%9F%8E%A4), but I wanted to make sure you feel confident that I have deeply considered this choice, talked through the choice with Swift Concurrency experts, and have tested to make sure there are no performance implications.
  185. ### Documentation
  186. If you have any questions I would ask that you please look at the documentation first, both Boutique and Bodega are very heavily documented. On top of that Boutique comes with not one but two demo apps, each serving a different purpose but demonstrating how you can build a Boutique-backed app.
  187. As I was building v1 I noticed that people who got Boutique loved it, and people who thought it might be good but had questions grew to love it once they understood how to use it. Because of that I sought out to write a lot of documentation explaining the concepts and common use cases you'll encounter when building an iOS or macOS app. If you still have questions or suggestions I'm very open to feedback, how to contribute is discussed in the aptly named [Feedback](#feedback) section of this readme.
  188. - [Boutique Documentation](https://build.ms/boutique/docs)
  189. - [Bodega Documentation](https://build.ms/bodega/docs)
  190. - [Boutique Demo App](https://github.com/mergesort/Boutique/tree/main/Demo)
  191. - [Performance Profiler App](https://github.com/mergesort/Boutique/tree/main/Performance%20Profiler)
  192. ---
  193. ### Further Exploration
  194. Boutique is very useful on its own for building realtime offline-ready apps with just a few lines of code, but it's even more powerful when you use the Model View Controller Store architecture I've developed, demonstrated in the `NotesController` above. MVCS brings together the familiarity and simplicity of the [MVC architecture](https://developer.apple.com/library/archive/documentation/General/Conceptual/DevPedia-CocoaCore/MVC.html) you know and love with the power of a `Store`, to give your app a simple but well-defined state management and data architecture.
  195. If you'd like to learn more about how it works you can read about the philosophy in a [blog post](https://build.ms/2022/06/22/model-view-controller-store) where I explore MVCS for SwiftUI, and you can find a reference implementation of an offline-ready realtime MVCS app powered by Boutique in this [repo](https://github.com/mergesort/MVCS).
  196. We've only scratched the surface of what Boutique can do here. By leveraging Bodega's `StorageEngine`, you can build complex data pipelines that do everything from caching data to interfacing with your API server. Boutique and Bodega are more than libraries, they're a set of primitives for any data-driven application, so I suggest giving them a shot, playing with the [demo app](https://github.com/mergesort/Boutique/tree/main/Demo), and even building an app of your own!
  197. ---
  198. ### Coding Agent Plugins
  199. Boutique ships with plugins for [Claude Code](https://claude.ai/code) and [Codex](https://developers.openai.com/codex). These plugins provide skills that will help your coding agent integrate and work with Boutique's APIs correctly. Now you'll be able to spend more time building apps and less time wondering if your agent is hallucinating APIs.
  200. #### Claude Code
  201. Adding the Boutique plugin to Claude Code takes three steps. Open Claude Code and run these commands:
  202. ```bash
  203. /plugin marketplace add mergesort/Boutique
  204. /plugin install boutique@boutique
  205. /reload-plugins
  206. ```
  207. After installing, run `/reload-plugins` and the plugin good to go.
  208. #### Codex
  209. Adding the Boutique plugin to Codex is even easier. Open Codex and run these commands:
  210. ```bash
  211. codex plugin marketplace add mergesort/Boutique
  212. ```
  213. When you run Codex and type `/plugins`, Boutique will now show up in the list. And if you've cloned the Boutique repo locally, Codex will automatically detect the plugin from the repo's marketplace file.
  214. ---
  215. ### Feedback & Contribution
  216. This project provides multiple ways to deliver feedback to maintainers.
  217. - If you have a question about Boutique, we ask that you first consult the [documentation](https://build.ms/boutique/docs) to see if your question has been answered there.
  218. - This project is heavily documented but also includes multiple sample projects.
  219. - The first app is a [Demo app](https://github.com/mergesort/Boutique/tree/main/Demo) which shows you how to build a canonical Boutique app using the Model View Controller Store pattern. The app is heavily documented with inline explanations to help you build an intuition for how a Boutique app works and save you time by teaching you best practices along the way.
  220. - The second app is a [Performance Profiler](https://github.com/mergesort/Boutique/tree/main/Performance%20Profiler) also using Boutique's preferred architecture. If you're working on a custom `StorageEngine` this project will serve you well as a way to test the performance of the operations you need to build.
  221. - If you still have questions, suggestions for enhancements, or ways to improve Boutique, this project leverages GitHub's [Discussions](https://github.com/mergesort/Boutique/discussions) feature.
  222. - If you find a bug, please report it by creating an issue.
  223. ---
  224. ### Requirements
  225. - iOS 17.0+
  226. - macOS 14.0+
  227. - Xcode 15+
  228. ### Installation
  229. #### Swift Package Manager
  230. The [Swift Package Manager](https://www.swift.org/package-manager) is a tool for automating the distribution of Swift code and is integrated into the Swift build system.
  231. Once you have your Swift package set up, adding Boutique as a dependency is as easy as adding it to the dependencies value of your `Package.swift`.
  232. ```swift
  233. dependencies: [
  234. .package(url: "https://github.com/mergesort/Boutique", from: Version(3, 0, 0)),
  235. ]
  236. ```
  237. #### Manually
  238. If you prefer not to use SPM, you can integrate Boutique into your project manually by copying the files in.
  239. ---
  240. ### Coding Agent Plugins
  241. Boutique ships with plugins for [Claude Code](https://claude.ai/code) and [Codex](https://developers.openai.com/codex). These plugins provide skills that will help your coding agent integrate and work with Boutique's APIs correctly. Now you'll be able to spend more time building apps and less time wondering if your agent is hallucinating APIs.
  242. #### Claude Code
  243. Adding the Boutique plugin to Claude Code takes three steps. Open Claude Code and run these commands:
  244. ```bash
  245. /plugin marketplace add mergesort/Boutique
  246. /plugin install boutique@boutique
  247. /reload-plugins
  248. ```
  249. After installing, run `/reload-plugins` and the plugin good to go.
  250. #### Codex
  251. Adding the Boutique plugin to Codex is even easier. Open Codex and run these commands:
  252. ```bash
  253. codex plugin marketplace add mergesort/Boutique
  254. ```
  255. When you run Codex and type `/plugins`, Boutique will now show up in the list. And if you've cloned the Boutique repo locally, Codex will automatically detect the plugin from the repo's marketplace file.
  256. ---
  257. ### About me
  258. Hi, I'm [Joe](http://fabisevi.ch) everywhere on the web, but especially on [Bluesky](https://bsky.app/profile/mergesort.me).
  259. ### License
  260. See the [license](LICENSE) for more information about how you can use Boutique.
  261. ### Sponsorship
  262. Boutique is a labor of love to help developers build better apps, making it easier for you to unlock your creativity and make something amazing for your yourself and your users. If you find Boutique valuable I would really appreciate it if you'd consider helping [sponsor my open source work](https://github.com/sponsors/mergesort), so I can continue to work on projects like Boutique to help developers like yourself.
  263. ---
  264. **Now that you know what's *in store* for you, it's time to get started** 🏪

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.