Skip to content

Commit

Permalink
chore: Change the default value of isLoading in settings reducer to t…
Browse files Browse the repository at this point in the history
…rue (#34490)

## Description
This PR makes sure that the initial value of `isLoading` in the settings
reducer is set to true.
This flag is used to conditionally render the loading component and the
AdminSettings component in
`app/client/src/pages/AdminSettings/index.tsx`. This change makes sure
that the Admin Page components are not mounted and unmounted on initial
render. The mouting and unmounting used to happen earlier because the
flag switched from false => true => false.

Fixes #`Issue Number`  
_or_  
Fixes `Issue URL`
> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/9737924972>
> Commit: 553b867
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9737924972&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Sanity`

<!-- end of auto-generated comment: Cypress test results  -->




## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **Bug Fixes**
- Improved initial loading state of settings to enhance user experience
during app startup.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
  • Loading branch information
dvj1988 authored Jul 1, 2024
1 parent 938e7b4 commit f25cae0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/client/src/ce/reducers/settingsReducer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import type { TenantReduxState } from "@appsmith/reducers/tenantReducer";
import { tenantConfigConnection } from "@appsmith/constants/tenantConstants";

export const initialState: SettingsReduxState = {
isLoading: false,
isLoading: true,
isSaving: false,
isRestarting: false,
showReleaseNotes: false,
Expand Down

0 comments on commit f25cae0

Please sign in to comment.