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

posts/2024-06-13-eval-strings #15

Open
utterances-bot opened this issue Jun 26, 2024 · 1 comment
Open

posts/2024-06-13-eval-strings #15

utterances-bot opened this issue Jun 26, 2024 · 1 comment

Comments

@utterances-bot
Copy link

Josiah Parry - Evaluate strings as code

https://josiahparry.com/posts/2024-06-13-eval-strings

Copy link

yihui commented Jun 26, 2024

I think the best solution was given by @klmr:

getExportedValue('dplyr', 'starwars')

IHMO eval() should really be used as the very last resort. In most cases, there may exist a cleaner and safer way to achieve the task.

BTW, I'm not sure if there's any benefit of using {rlang} vs eval(parse(text = dataset_str)).

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

No branches or pull requests

2 participants