If Twitter can write a webpage that provides the functionality in only 1Mb then what is in the mobile app?
That doesn't include the 17 other frameworks all over 1Mb in size (there are innumerable other smaller frameworks) for periscope and other features.
Seems to me they could ship a 5Mb app that just wraps the Twitter web site and provides iOS native experience (notifications, apple watch, etc) and call it a day.
I believe that, currently, if you iOS app uses any Swift code, you have to include the Switch libraries in your app. This has something to do with how quickly Swift has been changing, and Apple wanting you to reference your own library instead of the system one for now.
This has caused a number of apps to balloon in size lately, but the hope is that it is temporary.
It is unfortunate that apps can't dynamically link to standard swift libraries in the OS, but that still doesn't explain the other 150Mb of binaries.
[0] https://f-droid.org/repository/browse/?fdfilter=twidere&fdid...
1 MB is “acceptable” by today’s standards, but when you think about it — 1 MB to display a few 140-character tweets?
You've got routing, templates, event handlers, search, a lightbox, settings pages, the whole DM chat-style interface, the whole posting interface, and probably more that I'm not even thinking about.
Now I'm not saying that it couldn't be smaller - quite probably even substantially smaller. It'd be great to get it down to 100KB. I bet you could have a much smaller first load for just the feed, and then dynamically load in the JS for the other routes as they're requested. That could then be cached locally with service workers.
Edit: Looks like they do actually already do that. I just unregistered their Service Worker and refreshed - my load was ~300KB. Still kinda weighty but a lot less than 1MB.
From https://blog.twitter.com/2017/how-we-built-twitter-lite:
> the app streams the initial HTML response to the browser, sending instructions to preload critical resources while the server constructs the initial app state. Using webpack, the app’s scripts are broken up into granular pieces and loaded on demand. This means that the initial load only requires resources needed for the visible screen. (When available, a Service Worker will precache additional resources and allow instant future navigations to other screens.) These changes allow us to progressive load the app so people can sooner consume and create Tweets.
For comparison, Tweetbot is 7.6MB and Twitterific is 10.3MB (both on iOS), and they provide a much nicer experience for using Twitter than the official app.