Re:Show HN: My first native iOS app – Cone, a real time colo...
by coreymaass on Wednesday May 03, 2017 @11:42AM
(#14256706)
If you're willing to go lossy, also look at PNGQuant - https://pngquant.org/ I've started using it on all of my web images. I've yet to see the loss on a couple dozen images, but the size drops by up to 66%, even after being run through imageoptim.
Re:Show HN: My first native iOS app – Cone, a real time colo...
by kookiekrak on Thursday May 04, 2017 @03:01AM
(#14263062)
tinypng is actually based on pngquant + more optimizations not in pngquant
Re:Show HN: My first native iOS app – Cone, a real time colo...
by tehlike on Wednesday May 03, 2017 @12:21PM
(#14257201)
Webp is much better for compression, but is support does not exist.
Re:Show HN: My first native iOS app – Cone, a real time colo...
by _kush on Wednesday May 03, 2017 @11:33PM
(#14262241)
Usually, my website projects have a couple grunt tasks running for image compressing, minimizing files, etc., but for this landing page, I just went with the basic HTML and CSS workflow. I realized how easy it was to create a website when there was no grunt or other dependencies haha.
However, I'll definitely be optimizing the files. Thank you for the tip!
Re:Show HN: My first native iOS app – Cone, a real time colo...
by mizaru on Wednesday May 03, 2017 @03:04PM
(#14258990)
30MB for the app itself seems excessive, though.
Re:Show HN: My first native iOS app – Cone, a real time colo...
by trevor-e on Wednesday May 03, 2017 @08:52PM
(#14261581)
Most of that is probably due to Swift's runtime library.
Re:Show HN: My first native iOS app – Cone, a real time colo...
by developer2 on Thursday May 04, 2017 @12:56AM
(#14262551)
Surely if you're using core Swift, or core Objective-C, the runtime is a shared lib shipped with the OS? I can't imagine that every single app built on Swift or Objective-C is bundling the exact same foundation? That seems so unlike Apple to miss such a massive optimization to reduce the download size of nearly every app. I can understand there being exceptions with some apps that use custom setups, but surely the majority of apps are written in XCode using exactly what is provided as a toolset.
Re:Show HN: My first native iOS app – Cone, a real time colo...
by nicky0 on Thursday May 04, 2017 @11:58AM
(#14265835)
> I can't imagine that every single app built on Swift or Objective-C is bundling the exact same foundation
In fact, every single app built on Swift is bundling the full set of runtime libraries, both on iOS and Mac. This will continue until the Swift ABI is finalised.
This is why I don't ship Swift yet.
Re:Show HN: My first native iOS app – Cone, a real time colo...
by simonbarker87 on Thursday May 04, 2017 @07:10AM
(#14263967)
I'm not an expert in the why, but as far as I am aware the whole of Swift is shipped as part of each app as it is still being developed. There is a road map to ship with the OS I believe but it's not for a while
Re:Show HN: My first native iOS app – Cone, a real time colo...
by connoljo on Thursday May 04, 2017 @10:38AM
(#14265124)
It's because swift doesn't have ABI stability yet.
Re:Show HN: My first native iOS app – Cone, a real time colo...
by simonbarker87 on Thursday May 04, 2017 @10:49AM
(#14265204)
Thanks
Just FYI:
1. You could save ~15.75kb by minifying your JS/CSS (a bit nit-picky since your resources are a fraction of what most sites have)
2. The 1MB background image comes out to 570.6 KB through tinypng.com (47% off!). If lossless is more your thing, you could save about 5% by running it through something like imageoptim.