mapbox-navigation-ios icon indicating copy to clipboard operation
mapbox-navigation-ios copied to clipboard

Use Swift linter to ensure code quality.

Open azarovalex opened this issue 4 years ago • 0 comments

There is a company-wide discussion about lint usage in Swift code: https://github.com/mapbox/apple-internal/issues/20.

We've already encountered a couple of crashes because we didn't forbid the usage of force unwrapping and implicit optional. @1ec5 proposed to add a linter to warn about unsafe code here: https://github.com/mapbox/mapbox-directions-swift/issues/453

In addition, sometimes I review PRs and come across trivial typos that a linter could have caught during the development. Adding a linter can help us here. An example of such a PR: https://github.com/mapbox/mapbox-navigation-ios-examples/pull/89.

As a reference, Nikolay from 1Tap recently added a SwiftLint: https://github.com/mapbox/1tap-ios/pull/128

azarovalex avatar Apr 15 '21 15:04 azarovalex