-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Discontinue Objective-C compatibility #381
Comments
Work is happening in #382. |
mapbox/mapbox-speech-swift#31 removes Objective-C support as well. |
Tail work is being tracked in the following issues:
|
If your application is written in Objective-C, the changes in v1.0.0-alpha.1 don’t mean you have to rewrite your application in Swift, though you’re certainly free to do so. But you would at a minimum need to write a compatibility shim around the parts of MapboxDirections’ public API that your application uses. If you use the navigation SDK, mapbox/mapbox-navigation-ios#2231 (comment) has an example compatibility shim that you can adapt for your needs. |
We’re discontinuing support for applications written purely in Objective-C to use the iOS navigation SDK. The same change will take place in the iOS navigation SDK: mapbox/mapbox-navigation-ios#2231. Applications written in Objective-C will need to implement compatibility shims in Swift to continue to interoperate with this library.
Since #47, we’ve half-heartedly supported Objective-C by ensuring bridgeability of key APIs, but there are many gaps in coverage, and the public API in Objective-C feels like a translation from another language. A renewed focus on Swift will eliminate a major source of technical debt. We’ll be able to write more idiomatic, less error-prone Swift code without compromising the developer experience in both languages.
Discontinuing Objective-C support will have the following immediate impacts on the codebase:
@objc
attributes andMB
class prefixes will disappear.We’ll hopefully be able to take advantage of some Swift language features in the process:
/cc @mapbox/navigation-ios
The text was updated successfully, but these errors were encountered: