Closed palisadoes closed 1 year ago
@xoldyckk @noman2002
react-scripts
and I'd like to know whether we should consider removing it from the application. Should we?I read somewhere that these warnings arise due to conflicts between the packages we used. I don't know if it possible to remove all of them or not.
@noman2002 What about react-scripts
? We have close to a dozen reported vulnerabilities that cannot be updated because the latest version of react-scripts
requires vulnerable dependencies. Is there an alternative we could use?
is this somewhere related to issue #394 ? @palisadoes
@aashimawadhwa
react-scripts
?@aashimawadhwa i think you are working on #394 , so if you want you can assign this to me so that i can also give it a try
@aashimawadhwa
1. Yes it is. I forgot about that one. There may be a way to run a command to automatically fix the dependencies. 2. What are your thoughts about `react-scripts`?
i tired updating the dependencies automatically and right now i am doing everything manually
Hopefully when we get them all OK we can then add the test to GitHub actions so that we never have to go through this again.
@palisadoes I am following these resources
According to TL;DR: peerDependencies is for dependencies that are exposed to (and expected to be used by) the consuming code, as opposed to "private" dependencies that are not exposed, and are only an implementation detail.
If P1 and P2 indeed both have peer dependencies on incompatible versions of P3 you will need to either find versions of P1 and P2 with compatible peer dependencies of P3 or abandon the use of either P1 or P2. @palisadoes
and abandoning dependencies does not feel right to me for some reason, it will break the code to great extent.
I updated all the packages in package.JSON and tried everything but the npm warnings still exists. @palisadoes
Thanks for the effort @aashimawadhwa .
react-scripts
.
The react-scripts repository has not been updated in 10 months on GitHub and 10 months in npm. I'm concerned support may have ended.
1.) For warnings there are no changes as of now , if we look closely into them many dependencies are deprecated and therefore the warning is generated. 2.) most of the issues are there because of the react scripts , I am not sure if we should continue using them but we can use the following alternatives for react scripts i.e :
@palisadoes
Using deprecated packages is a risk we should not take. How easy would it be to do the replacement?
@noman2002 @xoldyckk what are your thoughts?
It it a bit tedious task to change packages as we might not have exact same replacement for it. I think we should keep this as it is for now and update in one of gsoc projects.
Thanks Noman,
@palisadoes create-react-app is outdated. It focuses on backwards compatiblity when web ecosystem is moving forward at a rapid rate. Modern web technologies don't work with create-react-app and even if they somehow do you'll spend more time configuring create-react-app than working on the business logic. This is because all configuration in create-react-app is abstracted away using react-scripts. Also it's built on webpack which is extremely slow and sucks for developer productivity.
I'd recommend migrating the project to vite with react and typescript.
Wdyt Craco migration will help ? @xoldyckk
@aashimawadhwa It may work but it's a wasted effort. Even when using craco you're still relying on create-react-app indirectly. You're trying to maintain a whole legacy module system based on babel and webpack by yourself. If something in create-react-app's core is broken craco can't fix that.
There's a whole war going on with official react team and big influencers and developers in javascript ecosystem to ban the recommendation of using of create-react-app in react docs.
Look:- https://github.com/reactjs/reactjs.org/pull/5487
And it'll be soon either deprecated or make breaking changes which will not be backwards compatible with older versions of create-react-app. So, either way work has to be done. So, if you're going to do it, do it with what the industry standard is right now.
So wdyt updating the yarn.lock and package.json will create some difference?? @palisadoes @xoldyckk
@aashimawadhwa btw talawa-admin uses an outdated version of yarn too. It uses v1 when current yarn version is v3.
I tried using it with yarn v3 it broke. Idk what's going on but yarn v1 and talawa-admin have some magic going on behind the scenes. And magic is bad.
Describe the bug
To Reproduce See above
Expected behavior
Actual behavior
See above
Screenshots This is sample output from the
npm i --package-lock-only
commandAdditional details See above