-
Notifications
You must be signed in to change notification settings - Fork 38
Add explicit bundle parameter to support frameworks #17
Conversation
Do note I first want to merge the other PRs related to linting and compilation, to avoid further issues with the output code. |
I like that change and approve this PR, but wouldn't it a breaking change, because
|
Oh yeah I didn't notice that. I'd vote for keeping the initializer. |
9de94a6
to
51bfc6b
Compare
Yeah, in Swift you can't return a different object in the I've re-added the init for both platforms. On macOS it falls back to the old behaviour. |
51bfc6b
to
4c4a611
Compare
Cool! One last question, I'm wondering if the It's not much, but given that this Mixin isn't necessary per se and generating the init directly doesn't change the amount of code or the complexity, maybe it's not worth it risking a name conflict? |
38ce5ed
to
cf66111
Compare
@djbe now that inits are back, this should be mergeable right now, even in upcoming 4.2, as it isn't breaking anymore, right? |
Jup, should be 👌 |
Carry over changes from SwiftGen/SwiftGen#255 with some added fixes for Swift 2.3. I've also implemented the same changes for storyboards.
This still needs some work to add this to the other commands, for example:
UIImage(named:in:compatibleWith:)
) and macOS (bundle.image(forResource:)
)CTFontManagerRegisterFontsForURL
before use. I've done this using an override ofinitialize()
in a Font extension, but we could also just check in ourinit
if it's already loaded. Would love some input on the preferred method for this.