Expo publishing just hangs - expo

When I expo publish all I ever get is:
› Expo SDK: 44.0.0
› Release channel: default
› Workflow: Managed
Building optimized bundles and generating sourcemaps...
Starting Metro Bundler
iOS Bundling JavaScript [==== ] 6%
and it stays there forever. I've tried clearing all caches, deleting .expo and node_modules and still get the same result. I get the same result in CI (GitHub Actions) with a fresh container.
Does Expo publishing just occasionally go for periods when it does't work at all (because of backend issues)?

FWIW this was entirely my fault. I was generating huge bundles by importing way too much of Fontawesome.
Make sure that when you are using resources that you are careful not to add things that you don't need but that increase the bundle size.

Related

Gatsby local build different from AWS Amplify build?

I have a Gatsby site that is working perfectly fine when I build and serve on localhost, but when I push the code and check my AWS Amplify website (that is tracking the github repo), it's behaving very differently. For example, on my local production build, all the links are working properly and view page source shows HTML.
However, on my Amplify link, only some of the link paths are working, and view page source is not showing any HTML for any of the pages. I assume there must be some kind of difference between the way it's being built on my local machine and on Amplify, but I'm not sure exactly where the exact problem is lying.
In theory, since they're both production builds and not development, they should be behaving the same way?
I assume there must be some kind of difference between the way it's
being built on my local machine and on Amplify, but I'm not sure
exactly where the exact problem is lying.
I also think so. These kinds of issues (different behavior between environments) are usually related to Node versions. hence the installed dependencies version differs between environments.
In your case, check the current local version by running node -v and set the version to AWS Amplify (it uses nvm underlying).
You can follow one of the multiples approaches suggested in:
How to change Node Version in Provision Step in Amplify Console
frontend:
phases:
preBuild:
commands:
- nvm install 10
Change 10 for your local version.
Gatsby is a static site generator if you are adding new pages separately as an html link, at the build time it will be removed. You need to add them under the pages folder as a react component itself and use Link from gatsby to navigate across the pages

React-device-info issue in expo and ui-kitten

Good morning every body,
I'm having an issue using expo and ui-kitten. I'm pretty much familiar
with react-native-element as UI library for react native. But I found
out that ui-kitten has some stunning features for theming and styling
in react-native, expo and I follow this link
https://github.com/akveo/react-native-ui-kitten explained by
https://justinnoel.dev/2019/12/21/create-universal-react-native-apps-using-expo-for-web-and-ui-kitten.
In the app's directory I have the regular expo folders and another folder src where ui-kitten components rely.
But When trying to design my app using ui-kitten glossary, I was asked to install #react-native-community/react-device-info which is used by a component inside node-module.
The problem occurs when I use DateFns in the app to parse and format dates. Install #ui-kitten/date-fns ends up with this error " Error #react-native-community/react-device-info : NativeModule.RNDevice is null ". I tried the suggested steps by stack trace:
To link react-device-info to react-native if my react native version
was <=0.59, but mine is 0.61.4
To instal pod if I was using cocoa pod, but I'm not.
To rebuilt and re-run ( I rebuilt and re-run using same steps and
got same result).
The screen is here
So how can I fix this error which to me seem to be having no real clue whether it's from expo's dependencies or from a bug inside ui-kitten modules, or a conflict between the two.
Any help will be much appreciated !
THIS IS MY CONTEXT:
The main goal is to use ui-kitten along with expo features
I run the app on android emulator
The problem started after installing date-fns. Is expo not able to retrieve native data such as date time or calendar from device? How to fix that.
Thanks in advance.
UI Kitten has no common with react-native-device-info. If you're not using Expo, you should do exactly what the error says: link the library.
If you do, see Expo implementation for this package.
There are two way to troubleshoot this issue, by ejecting expo or by rebuilding another app. The fact is that expo does not support native modules such as device time or geolocation, I just forgot. That said using device's properties with expo is not feasible.
So the first approach is to eject expo by running expo eject. But it goes across the bord that expo has some facilities regarding dependencies and deployments. So the best option is to rebuild another expo app with ui-kitten but avoiding to use any feature from react-native and ui-kitten that calls the device info, and after deployment add the functionalities of the app that require the device's features such camera, geolocation or device's date and time.

JavaScript Bundle getting build every time it finish building. Expo XDE

Hope you guys can help me with this weird issue I'm facing.
The app bundle is getting build everything time it finishes building. So its like once it gets to 100% it starts all over again. One thing I made to kind of solve it, is to enable the "Remote debugging" option on the expo App. But that will only work for a minute and will start the loop of building the bundle again.
I have also reinstalled the node_modules & cleaned expo cache but nothing seems to be working.
Ok, I found it. It was because of iCloud Drive on MAC. For some reason that I don't understand (since it did not happen before under the same conditions) the refresh of the files is forced.
So move your app folder to another place that is not on iCloud Drive and it will work.
Hope this will help.
It was Dropbox sync causing my issue.
Most of the time you shouldn’t need to rebuild your APK on every change, you should only need to run exp publish to see your updated app show up in your existing APK. If you change anything in app.json you’ll need to run the build again, but if you aren’t touching app.json then you should be mostly fine to just publish and not run a standalone build.

Refreshing Code modifications - JHipster

I'm a new user of this tool. After having installed the environment on my cpu, I tried first to add some code to the home component (for example).
Unfortunately, when I save my modifications and refresh the page, there is no update.
Do you may have some things to check if it happens ?
As seen in the comments - just run yarn start, as explained in the documentation, to have TypeScript compilation and hot reload working.

What do you do when ember-cli rimraf node_module requires glob and returns 'undefined is not a function'?

While attempting to migrate ember apps to ember-cli rather than grunt-cli, HTMLBars rather than handlebars and history API rather than hashchange, my new test projects got a 'undefined is not a function' due to the rimraf module now requiring glob and some problem in using that.
I still had a working project where ember-cli node_modules have the older rimraf so I replaced the CLI node_modules with the older ones and was able to get test projects running again. I'm still using ember-cli 0.2.0-beta.1 because 0.2.0 caused me other issues.
This issue with dependencies being out of line was probably temporary since revisions within CLI are happening so fast. If I came back the next day and cleared out module and component cache and started over, it probably would have cleared up. By reverting CLI manually I wound up with other issues with express live update, so would have to stop and restart express after every edit. I realized I wasn't ready to re-write my gruntfile as a brocfile and deal with all the other issues with migrating to Ember CLI, so started over by updating the Ember dependency in my grunt-based project and going that route, which is also frustrating and hugely problematic, but I'm sure I'm farther along in this route than I would have been in re-writing for Ember CLI.