Skip to content

In-memory To-Do with entity + controller layers; mirrors Core Data patterns and runs in an online Swift runner.

deepthipathlawath20/swift-persistence-todo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 

Repository files navigation

Swift Persistence (To-Do)

In-memory CRUD that mirrors Core Data ideas (entities, identity, queries) with a clean controller layer. Runs anywhere (even online Swift runners).

What’s here

  • Models.swiftTodoItem entity + display helpers
  • TodoStore.swift — store protocol + in-memory store
  • TodoController.swift — business logic (add, toggle, list)
  • main.swift — small demo that prints the list

Run (web)

Use an online Swift runner. Paste all four files into one editor pane in this order:

  1. Models.swift
  2. TodoStore.swift
  3. TodoController.swift
  4. main.swift
    Then click Run and copy your output below.

Sample Output

All:
[x] Buy groceries
[ ] Study Swift

About

In-memory To-Do with entity + controller layers; mirrors Core Data patterns and runs in an online Swift runner.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages