Shorten URL
Completed
Mar 2022 - Mar 2022 (1 month)
Shorten URL is an iOS assignment project that implements a complete URL-shortening flow with SwiftUI screens, input validation, API integration, and persistent link history.
The implementation evolved through incremental commits from UI setup to layered architecture, then production-oriented hardening with networking, persistence, and refactoring cleanup.
Built with: Swift, SwiftUI, Core Data, Combine, CocoaPods, Alamofire, SwiftyJSON, XCTest, and XCUITest.
Links
Project Activity
Recent updates for Shorten URL. Completed
March 2022
-
Refactored UI constants into dedicated helper files (fonts/images/labels), renamed and reorganized shared views, and reduced magic values across the SwiftUI screen layer.
-
Integrated Core Data persistence through new worker/publisher layers, replaced DataManager with Repository abstractions, and wired delete-link handling into view models and screens.
-
Implemented domain-layer add-link networking with Alamofire + SwiftyJSON, expanding ShortLink modeling and updating AddNewLink/ShortLinks view models to consume live API responses.
-
Added SwiftyJSON via CocoaPods and updated pod integration files to support JSON response parsing in the URL-shortening flow.
-
Introduced Alamofire/CocoaPods workspace setup, added AddNewLinkViewModel plus loading indicator support, and connected early networking logic to Add New Link UI.
-
Added URL text-field validation messaging and small-text UI support to improve invalid-input handling in Add Link flow.
-
Applied UI customization pass across AddLink, Link, Main, NoData, and SavedLinks views, including shared Combine helper cleanup.
-
Fixed keyboard interaction issues affecting Add Link entry and Main view usability during text input.
-
Built the Add Link SwiftUI interface with reusable UI extensions and button updates to establish the primary link-submission surface.
-
Patched MainView behavior to resolve a small runtime/UI issue during the ongoing saved-links integration phase.
-
Added Poppins font assets, extracted reusable text/button view components, and applied broader SwiftUI visual customization across main list surfaces.
-
Implemented copy-button functionality in LinkView and introduced shared color helpers to support interactive copied-state styling.
-
Removed mock data-manager usage from real app screens by updating MainView and SavedLinksView wiring toward production data flow.
-
Delivered initial saved-links listing experience with asset imports (logo/banner/shape/delete), plus new AddLink/Link/NoData/SavedLinks SwiftUI screens.
-
Introduced core business structure with ShortLink model, DataManager/MockDataManager, ShortLinksViewModel, and reorganized assets/CoreData/helper paths.
-
Built the first SwiftUI MainView baseline with background styling, app entry updates, and initial extension scaffolding.
-
Initialized an empty Xcode SwiftUI project with Core Data model, app target, and XCTest/XCUITest targets as the foundation for the assignment.
-
Added Xcode-focused gitignore rules to keep local/build artifacts out of version control from day one.
Objective Link to heading
- Build a native iOS URL-shortening app that accepts long links, validates input, calls the shrtcode API, and returns copy-ready short links.
- Persist link history locally so users can revisit, copy, and delete previously generated short links across app launches.
Product workflow Link to heading
- Enter a URL in the add-link form and validate empty/invalid states.
- Submit valid links to the shortening API and parse responses.
- Append successful results into the saved-links history list.
- Support one-tap copy actions and per-item deletion from history.
- Keep history durable through local persistence.
Architecture evolution Link to heading
- Started from a SwiftUI baseline, then introduced model/view-model/data-manager responsibilities.
- Added networking through Alamofire + SwiftyJSON for link creation.
- Integrated Core Data persistence for saved links and removed mock-only wiring.
- Refactored shared constants into helper files (labels/fonts/images) to reduce magic values and simplify maintenance.