Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add devTools flag to config and use it to gate EntityBranchData #1100

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

matthew-white
Copy link
Member

This comment on the release criteria for v2024.2 asks whether we should prevent showing EntityBranchData unless a Frontend config is set. I think that's a good idea. It's not impossible that a user would randomly click "Offline update", and it'd be confusing if they did.

What has been done to verify that this works as intended?

I tried it out locally. If the config is set to true, I can see the modal, and if it's set to false, I can't. Since this modal is only for development/testing, I don't think we need to write automated tests about it.

Why is this the best possible solution? Were any other approaches considered?

I named the config something generic: devTools. In the future, I think there will probably be other examples of things like this modal.

Before submitting this PR, please make sure you have:

  • run npm run test and npm run lint and confirmed all checks still pass OR confirm CircleCI build passes
  • verified that any code or assets from external sources are properly credited in comments or that everything is internally sourced

@@ -154,7 +155,8 @@ const requestDelete = () => {
.catch(noop);
};

const branchData = modalData();
const EntityBranchData = defineAsyncComponent(loadAsync('EntityBranchData'));
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The component will only be loaded if it's rendered (if the v-if is true). So it won't ever have to be loaded for users.

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

Successfully merging this pull request may close these issues.

2 participants