Source code for the WriteFreely SwiftUI app for iOS, iPadOS, and macOS
Go to file
Angelo Stavrow a51bbd3abc
Alert on error: shared code (#207)
* Initial work on presenting alert on error

* Move Account-related error handling up the hierarchy

* Handle errors on logout

* Fix for temporary debugging

* Clean up WriteFreelyModel’s published vars

* Add error handling to top-level content view

* Set current error on API call failures

* Set current error on API call handlers

* Move User Defaults errors to ErrorConstants file

* Add default values for some error strings

* Handle purging post errors

* Add FIXME to track silent failure on fetching collections

As collections are fetched and added to the `list` property in the CollectionListModel’s initializer, it’s tricky to throw an error here: we call it as a property initializer in CollectionListView, which cannot throw.

Consider refactoring this logic such that we’re using, for example, a @FetchRequest in CollectionListView instead.

* Handle errors in (most) shared code

Two outliers to come back to are:

- the LocalStoreManager, where we can’t set a current error in the WriteFreelyModel in methods that can’t throw
- the CollectionListModel, where the initializer can’t throw because we use it as a property initializer in CollectionListView

* Add error handling to Mac app

* Revert "Add error handling to Mac app"

This reverts commit b1a8b8b29c.
2022-07-27 09:56:32 -04:00
ActionExtension-iOS Clean up project warnings (#199) 2022-04-02 08:04:50 -04:00
iOS Alert on error: shared code (#207) 2022-07-27 09:56:32 -04:00
macOS Clean up project warnings (#199) 2022-04-02 08:04:50 -04:00
Shared Alert on error: shared code (#207) 2022-07-27 09:56:32 -04:00
Technotes Add troubleshooting/deploy details to technote 2021-01-05 16:30:15 -05:00
Tests iOS Add SwiftLint and sort out boilerplate warnings and errors 2020-07-22 10:17:11 -04:00
Tests macOS Add SwiftLint and sort out boilerplate warnings and errors 2020-07-22 10:17:11 -04:00
WriteFreely-MultiPlatform.xcodeproj Alert on error: shared code (#207) 2022-07-27 09:56:32 -04:00
.gitignore Update minimum required version of WriteFreely Swift package 2021-05-20 16:43:28 -04:00
.swiftlint.yml Implement basic post store and list / editor UI components 2020-07-25 07:02:11 -04:00
CHANGELOG.md Update change log and bump version 2022-04-02 09:43:53 -04:00
CODE_OF_CONDUCT.md Add project metadocuments 2020-07-22 11:54:01 -04:00
CONTRIBUTING.md Add project metadocuments 2020-07-22 11:54:01 -04:00
LICENSE.md Swift from AGPLv3 to GPLv3 2020-07-30 10:39:13 -04:00
README.md Update README with office hours link 2021-05-04 15:49:08 -04:00
WFACollection+CoreDataClass.swift Add WFACollection NSManagedObject class for local storage 2020-09-08 09:54:58 -04:00
WFACollection+CoreDataProperties.swift Fetch user collections into CoreData and list from ManagedObjectContext 2020-09-08 09:55:43 -04:00
WFAPost+CoreDataClass.swift Add WFAPost NSManagedObject class for local storage 2020-09-08 09:57:05 -04:00
WFAPost+CoreDataProperties.swift Add wasDeletedFromServer flag to WFAPost entity 2020-09-17 14:31:45 -04:00
WriteFreely-MultiPlatform (iOS).entitlements Add App Group entitlement 2021-10-15 15:05:51 -04:00

WriteFreely SwiftUI MultiPlatform Client

A multiplatform (iOS, iPadOS, and macOS) client for WriteFreely, built in SwiftUI.

How To Get The Apps

The iOS app is now available on the App Store for iPhones and iPads running iOS 14. Check out this help forum topic for a guide on using the app.

The Mac app is still under development.

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

⚠️ Building and testing the iOS targets will work on any version of macOS that supports Xcode 12, but building and testing the macOS target requires macOS 11 (Big Sur).

SwiftLint is run as a build phase for all targets, so that linting warnings and errors are shown in Xcode.

Running the tests

To run the tests, select the scheme you want to test (iOS or macOS) and choose ProductTest from the Xcode menu.

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Need help getting started? Find out more about the project's office hours.

Versioning

We use SemVer for versioning and track changes in CHANGELOG.md. For the versions available, see the tags on this repository.

Authors

See also the list of contributors who participated in this project.

License

This project is licensed under the GPL v3 License. See the LICENSE.md file for details.