When I try to test my Nextjs project on PageSpeed Insights, I got two difference result, on Desktop view it ok, but on Mobile view I got the message Minimize main-thread work. How can I solve this problem?
On Mobile view
enter image description here
On Desktop view
enter image description here
Improve perfomance on Nextjs Project
Related
I've seen a bunch of stack overflow questions answered that address the problem of showing a desktop version on mobile, but I'm trying to discover how you could force a browser to render a mobile version of a site on desktop.
But is there some equivalent for desktop versions, so that I can 'trick' the browser into using media queries for a smaller device width? Essentially loading the mobile css onto the desktop version.
In essence I'm trying to add a toggle button that when clicked renders my page as though it were mobile. I'm aware you can achieve this affect with chrome tools, but I want to build in that functionality, and am struggling to figure out how to tell the browser to behave as though the viewport were mobile-sized.
Thank you!
if your CSS media queries doesn't work fine on desktop,
you're probably missing
<meta name='viewport' content='width=device-width' />
and if they work fine but you want your website to has same view in both mobile and desktop, then why are you using media queries at all?
remove them and your CSS will work on every size as the same
load the site on your mobile phone, take note of the url. If it has a "/m", for example, "https://www.example.com/m" then include it as such in your desktop browser and the mobile version would be loaded. It works for me.
I'm developing a ReactJS PWA. When I load the URL from my desktop and android, it works totally fine. But when I use iPhone, it shows a blank with a background image that I set to body tag. But it's blank.
By the way, I've used npx create-react-app for my project.
Can you please tell me why this is happening and what's the solution?
I'm using Skel.js and Skel-layers.js on a website I'm working on, I'm working on a modified HTML5Up template: http://html5up.net/escape-velocity
The problem I'm facing is that the collapsable navigation doesn't work on iOS (I've tried both Safari and Chrome). The collapsable nav works in every other web browser and mobile device. The original template works on iOS.
The HTML structure, and JS are the same. All the alterations within the CSS have no impact that I have found. I've been removing elements in the style-mobile.css and testing the alterations in the iOS Emulator on my Macbook.
The website I'm working on is http://havenlea-farms.co.uk/
When the collapsed nav icon is clicked, there is no response in iOS.
Has anyone got any ideas on what the cause could be? I'm aware that the question structure isn't great.
After much frustration I've found the problem. After manually unloading my stylesheets and javascript files, the problem was with an Arc Text lib I was using. https://github.com/codrops/Arctext
Once I removed the reference to the lib the navigation worked on iOS. I'll report this as a issue on GitHub for both Skel and Arctext.
Hello I'm creating a simple mobile app using Appgyver - steroids.
I'm new with this framework I'm trying to find a way to hide the loading screen between different pages in both Android and iOS. I have read their documentation but I can't make it work.
Based on this: http://docs.appgyver.com/en/edge/steroids_Steroids%20Native%20UI_steroids.layers_layers.push.md.html#steroids.layers.push
I 've set keepLoading: false on a view push which didnt work
also after the view push I called:
steroids.view.removeLoading();
as mentioned here: http://docs.appgyver.com/en/edge/steroids_Steroids%20Native%20UI_steroids.view_view.removeLoading.md.html#steroids.view.removeLoading
Nothing removed the black loading transition screen between pages.
Could someone please tell me what I'm doing wrong?
It could be documented better, but if you remove/rename the www/loading.html (for iOS) and www/loading.png (for Android) files in your project, then steroids.layers.push() will not show the loading screen (also means that the push animation will not start until after the WebView has loaded, which can take some time and lead to unresponsive feeling).
I have built an game using HTML and javascript that I want to turn into an ipad app.
I have been following this "Creating a native 'Objective-C' app" section of this guide: http://matt.might.net/articles/how-to-native-iphone-ipad-apps-in-javascript/
However, when I run the ipad simulator in Xcode, the "ipad" comes up, but it just shows a blank screen.
I took out all my code in my html file and just put in a couple of lines of html. When I change the background color, this does show in the ipad simulator.
However no text shows up.
Does anyone know what I'm missing?
I am using Xcode 3. Also, I have already taken my javascript file out of "compile sources" and placed it into "copy bundle resource".
I don't know about your problem but an easy way to create an HTML/JS app is to use PhoneGap. Plus you can bring your app to other OS like Android an a PhoneGap project is really easy to set up.
http://phonegap.com/start