Skip to content

Conversation

Dev-Ridwan16
Copy link

…dux)

feat: implement selection of testing library (jest) saving as dev dependency and addition of react-redux and redux toolkit

…dux)

feat: implement selection of testing library (jest) saving as dev dependency
@harshgupta20
Copy link
Owner

@Dev-Ridwan16 Please explain your changes in detail, all i can see is formatted lines and complete react app attached as test.

@Dev-Ridwan16
Copy link
Author

Feature: Enhanced Package Selection with Dev Dependencies Support

What was added:

1. Redux State Management Support:

    - Added @reduxjs/toolkit (Redux Toolkit) to optional packages
    - Added react-redux (React Redux bindings) to optional packages
    - Users can now easily add Redux state management to their React projects

2. Dev Dependencies Support:

    - Added new prompt for selecting development dependencies
    - Added Jest as the first available dev dependency option
    - Proper installation using npm install --save-dev

3. Technical Changes:

    - Enhanced Package Selection (lines 37-45): Added Redux Toolkit and React Redux to the optional packages list
    - New Dev Dependencies Prompt (lines 48-52): Added checkbox prompt for selecting dev packages like Jest
    - Variable Destructuring Fix (line 55): Added devPackages to properly extract from user answers
    - Installation Logic (lines 76-78): Added conditional installation of dev dependencies

Why these changes:

    - Redux Support: Provides popular state management solution that many React developers need
    - Dev Dependencies: Separates development tools from production dependencies for cleaner project structure
    - Better Developer Experience: One-command setup for complete React projects with testing and state management

Benefits:

    - Users can set up Redux state management during initial project creation
    - Testing framework (Jest) can be configured from the start
    - Maintains clean separation between production and development dependencies
    - Extensible foundation for adding more packages and dev tools

Testing:

    - Created test project demonstrating functionality
    - Redux packages install correctly when selected
    - Jest installs as dev dependency when selected
    - No impact on existing functionality when packages aren't selected

@Dev-Ridwan16 Dev-Ridwan16 removed their assignment Aug 21, 2025
@Dev-Ridwan16
Copy link
Author

@harshgupta20

@donymvarkey
Copy link

@Dev-Ridwan16, @harshgupta20.
I think this will be also a good adition to the project. But should we limit it to just redux toolkit? We also have many state management libraries. Like zustand, redux-saga, mobx etc. Additionally, we also have the context API as well. I guess we can just pick the most popular ones.

@harshgupta20
Copy link
Owner

@Dev-Ridwan16 @donymvarkey I am going to launch a new version which consist some new feature in 2.0.0 version this coming week.

Maybe, we will be focusing on TS support and state management configuration post new release of 2.0.0 version. I would like to give an option upto 3 state management tool on 2 second release update.
What do you think about this?

@donymvarkey
Copy link

Well, the TS support is a must. As per my knowledge, I suggest:

  1. redux-toolkit - Most of the people use this for a large scale application
  2. zustand - when devs want something lightweight and functional
  3. context API - may or may not use. depends upon the scenario.

Nowadays I see people use both zustand and redux-toolkit. What are your options that we need to add?
Can we post a community poll in linkedin for what state management library they use?

@harshgupta20
Copy link
Owner

@Dev-Ridwan16 @donymvarkey we will adding both, optional selection for Redux-toolkit or zustand, they can also skip the state management options entirely.

@donymvarkey
Copy link

That sounds great. We can move ahead with that.

@Dev-Ridwan16
Copy link
Author

@donymvarkey @harshgupta20 if people use Redux Toolkit and Zustand together in their app,
then we can treat it as a multiple selection.

For example:

Select a state management tool (enter the number):

  1. Redux Toolkit
  2. Zustand
  3. Redux Saga
  4. MobX

(Type the numbers to select multiple options, separated by commas)
→ User input: 1 (for single)
or
→ User input: 1,3,4 (for multiple)

@donymvarkey
Copy link

@Dev-Ridwan16 I don't think people will mix two or more state mnanagement libraries. They will pick one and use it through out the entire project. We can keep it a single selection.

@harshgupta20
Copy link
Owner

@Dev-Ridwan16 Yes, Please make it single selection.

@harshgupta20
Copy link
Owner

harshgupta20 commented Aug 27, 2025

@Dev-Ridwan16 Please resolve conflicts and take the latest pull

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants