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

[Feature Request]: Cleanup code specification in longitudinal app so it does not show all data-processing code on a Show Code button but it brings the code needed only for a specific module #50

Closed
3 tasks done
m7pr opened this issue Aug 11, 2023 · 1 comment
Assignees
Labels
core enhancement New feature or request

Comments

@m7pr
Copy link
Contributor

m7pr commented Aug 11, 2023

Feature description

Similarly to insightsengineering/teal.code#126 (comment) looks like code specification in longitudinal app is very limitied in specs, hence this shows the whole code of data processing when you click Show Code anywhere in any module in the app. I reckon this could be limited to just specific datasets.

image

Code of Conduct

  • I agree to follow this project's Code of Conduct.

Contribution Guidelines

  • I agree to follow this project's Contribution Guidelines.

Security Policy

  • I agree to follow this project's Security Policy.
@m7pr m7pr added enhancement New feature or request core labels Aug 11, 2023
@donyunardi
Copy link
Contributor

Based on the discussion, the reason for code repetition is our use of the #>code and <code technique, which can be found here: https://insightsengineering.github.io/teal/latest-tag/articles/preprocessing-data.html#usage-in-teal-apps.

The drawback of this approach is that users will encounter repeated code in every module, as previously mentioned.

To mitigate this, we considered passing the code argument in the cdisc_dataset(code=) function. However, this would make the app.R file excessively long and potentially difficult to comprehend for new users looking at the gallery.

The team has decided to maintain the current approach for the time being.
Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants