-
Notifications
You must be signed in to change notification settings - Fork 51
Conversation
Very cool! Contrary to the contribution guidelines, I'm actually wondering if this would be better as a parameter to I tend to think that if it matters which order methods are called in, that can be a bit of a code smell (I just searched and apparently it's called "temporal coupling"). On the other hand, long parameter list is a code smell too 😅 I think if I were to re-create this library, ... as you can tell I'm thinking myself in circles here :) @owulveryck do you have any thoughts? |
... just a start. Inspired by bmaupin/go-epub#65
After chewing on it for a couple minutes, I'm thinking that having this as a separate method (the way it currently is) is probably the simplest approach. I do think But I'd still be curious to hear if there are any other thoughts. |
it change to |
I suppose it could even be a parameter of the constructor to apply it to the whole Epub. But either way I think it's too much to refactor all of that now, so it makes the most sense to have this as a separate method. |
any specific things should be done or it good enough to merge right now? |
@bmaupin |
1a86fa3
to
6e68c84
Compare
9ffc44e
to
29bd431
Compare
@bmaupin finaly solve that and all test pass. |
@owulveryck What do you think? I was going to go ahead and merge it, but some changes were made to fetchmedia.go so I thought you might want to take a look first. Feel free to merge it if you think it looks okay, or I can later. I really like serving the test files from a local file server instead of getting them from the internet, since that should prevent broken URLs from breaking the tests. As for me the only thing that needs to be changed is the description for |
I will have a look by the end of this week. |
LGTM |
This PR add a method name
EmbeddedImages()
that download image inside thexhtml
than change EPUB to load show from included images instead of URL.Maybe close #26