Missing import chapter 2 line 173
sportfloh opened this issue · comments
hey,
the import statement #import "NetworkImageSource.h" is missing in chapter 2 on line 173
Cheers!
Ahh. Yes. That import
would have to be included at some point! This is a bug in the documentation. Thank you for opening this issue.
I think the fix on 173 would be an appropriate place. The reader might be a little confused why they would import
a file that does not (at that point) even exist (especially if they come from a Swift background where importing headers all the time does not happen). I could just add some explanation there and still keep the documentation consistent with a "test first" approach (we try to make use of the type and the header before they even exist).
The alternative would be to add the import
on 214 (after the header was created). I feel like the 173 fix might flow a little better and still communicate to the reader what is happening.
What are your thoughts about that? Would a fix on 173 or a fix on 214 be better for readers?
Ah, good point :-)
I first thought the 214 fix makes more sense because then you should have auto completion for the header, but Xcode isn't suggesting anything, maybe because the header is in an other target.
So I also think the 173 fix is the better way.
The fix has landed. Thanks for opening the issue!