JHipster: React option is not available [duplicate] - reactjs

While creating an app using JHipster, it is not showing React option for question "Which Framework would you like to use for the client?"

In v4.14.x, React support is still “experimental”, so you need to run jhipster --experimental to enable React support.
But no work has been done for React in v4.14.x the last weeks, so you should use the Generator JHipster v5.0.0-beta.1 instead.

Related

Can I use a react-native web module in a react app?

I have a module I created that uses #react-native-async-storage and I do know it uses LocalStorage for the web.
What I was wondering is whether I can use my module which uses #react-native-async-storage on a non-native react application?
I just tried to port it and it was giving me some errors starting up the app, but I think it's just my configuration.
Should I use react-native-web to convert a React-native app to a web app or implement it from scratch on React JS is a similar question, but I am looking for a smaller fragment of code rather than the whole app.

Can you use Next.js with a React Native App?

I have recently been learning Next.js for React and I like the routing system a lot more than react navigation. Now I am about to start a react native frontend and I was wondering if you can utilise Next.js's routing system in react native as well as it's other benefits. I know that you can use it with expo but I am a little confused as to how it all works and I am starting to wonder if the Next only works on the web side of things..
Does anyone have any experience with this? Any information would be much appreciated.
Thanks!
Unfortunately you can't do such thing, due to the fact that the views of react native are Equivalent to native views in Java or Objective C. When you get build version of react native , you are receiving Java or Objective C native views thank to react native's RN bridge. Meanwhile, when you get build version of your Next.js project, you are going to receive HTML, CSS, JS and these codes are not familiar to native platforms.
However, you can use your Next.js backend as your endpoints and fetch data in react native via calling this endpoints.
UPDATE Oct_2022:
there seem to be a new tool created for this purpose , called solito. I haven't used it personally but it might meet your needs.
UPDATE Jan_2023:
It looks like there are more Tools being created for Both web and native platforms , check react-native-web
You can check out Tauri. With that you can create from Next.js, React, Svelte etc. cross-platform native Apps. Currently, Windows, Mac and Linux are supported stable. Android & iOS is currently in Alpha
The magic behind Tauri is, that they provide around your Frontend library/framework a Rust layer with that you can interact with platform native APIs. They call it Commands.
You can find the guide for Next.js here.
Also, if it's not exactly answering the question - "Is it possible to use Next.js in React native?" - I hope that it's helping everyone who is searching for a solution to use Next.js as Cross-Platform Frontend Framework
I read a thread on ycombinator on this where Solito was mentioned and tried it out. In the comments I found this, which suited my needs best :
https://github.com/mlynch/nextjs-tailwind-ionic-capacitor-starter
Solito looks nice but the all in one repo was using Expo, which I did not like because it installs an extra app. I would check it out for yourself and look at the repo above too, which is using Capacitor and is aimed at having one codebase for the two apps.
Both examples worked well. For Tauri I could not find the mobile support so I didn't try it. I would be interested to read more about people's experience with running a minimum stack for cross platform development.
Note : Solito uses React Native, the repo uses Capacitor instead, which may also suite your needs because it works on both iOS and Android.
There's a lot of support now for this tech stack. Besides solito, which is already mentioned, there is also https://tamagui.dev/ which tries to solve all the issues with react-native-web and Next.js along with Solito.
While they currently recommend a monorepo (which adds a lot of complexity in my opinion), I'm playing around with a vanilla React Native + Next.js here: https://github.com/criszz77/luna
This command should get you started to play around:
npx react-native init MyAppName --template #criszz77/luna

Can I use react with #spartacus framework?

My question is, can I use the react framework with #spartacus storefront? this is because our frontend application is developed in React and we want to use #Spartacus storefront to leverage advantages like decoupling front-end and Hybris build ..etc. but as it is developed on angular I am not sure whether it supports other frameworks like React within it.
There is some effort in making possible using web components as cms components, so you could use any technology to author them (including React), but it's still in the experimental phase (but works already).
More info is available in the docs:
https://sap.github.io/cloud-commerce-spartacus-storefront-docs/customizing-cms-components/#using-web-components-as-cms-components-experimental-support
And here you can find some example POCs for React, Vue, and Svelte:
https://github.com/dunqan/react-cms-web-component
https://github.com/dunqan/vue-cms-web-component
https://github.com/dunqan/svelte-cms-web-component
Spartacus needs Angular. So, I would say "NO", unless you want the complexity of integrating Angular with React.

Include built ReactJS 16.x app into AngularJS 1.x

For a project I am working on, there is a situation where I have to include and ReactJS app which is already compiled into an AngluarJS project. Chrome/Firefox Browser is the Enduser-Interface.
I know that this setup isn't the best, unfortunately I have to deal with both frameworks in this exact setup.
I am not allowed to use an IFrame neither.
I googled a lot, searching for wrapper, which exists but only if the react project isn't already built.
Does anyone have a solution for this?
I am not sure your requirement, as per my understanding, you can import the "ngmodule" to react component and render the angular script. In this case you can achieve it from server side rendering.
In our project, we have the common login module developed in Angular 1.x, we are rendering the angular module in React.

Integrate reactjs with postgraphile

Am new to reactjs trying to integrate postgres with reactjs. Is there any way to integrate postgraphile with reactjs.
If so, please help me with a code or tutorial link.
Here are a collection of app examples using PostGraphile, some of these involve React:
https://github.com/graphile/postgraphile/wiki/App-Examples
Also check out https://github.com/graphile/examples and https://github.com/graphile/bootstrap-react-apollo
While there's already an accepted answer here, it missed stating something obvious: the way you "integrate reactjs and postgraphile" is by using a GraphQL client library (eg. Apollo, Relay, Lokka, etc.) in your React application to access the API that postgraphile creates.

Resources