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

Fixes #171

Merged
merged 12 commits into from
Mar 1, 2024
Merged

Fixes #171

merged 12 commits into from
Mar 1, 2024

Conversation

Noobware1
Copy link
Contributor

No description provided.

@ethanblake4
Copy link
Owner

ethanblake4 commented Feb 14, 2024

For the HttpStatus class there is a much simpler and better way to bridge it; because it's an abstract class that can't be instantiated and just has statics you can actually just do registry.addSource() with the original code of the class in a string, like we do in flutter_eval Colors.

@Noobware1
Copy link
Contributor Author

For the HttpStatus class there is a much simpler and better way to bridge it; because it's an abstract class that can't be instantiated and just has statics you can actually just do registry.addSource() with the original code of the class in a string, like we do in flutter_eval Colors.

That's auto generated tho should I remove it?

@ethanblake4
Copy link
Owner

Oh, nice. I'm assuming you still had to write the __static getter functions and registerBridgeFunc() stuff yourself though no?

Either way I would say it should be replaced, yeah. It's a lot more efficient to code it as a string if possible since the compiler can tree-shake unused values, plus in this case doing so is super easy. I should add a feature to detect this in the auto generator though.

@Noobware1
Copy link
Contributor Author

Oh, nice. I'm assuming you still had to write the __static getter functions and registerBridgeFunc() stuff yourself though no?

Either way I would say it should be replaced, yeah. It's a lot more efficient to code it as a string if possible since the compiler can tree-shake unused values, plus in this case doing so is super easy. I should add a feature to detect this in the auto generator though.

No, I wrote a handy eval generator to help me bridge packages I needed for my project so, I used it here too.

@ethanblake4
Copy link
Owner

No, I wrote a handy eval generator to help me bridge packages I needed for my project so, I used it here too.

That's really cool. If you're open to sharing the source I'd love to try to integrate that into dart_eval.

@ethanblake4
Copy link
Owner

ethanblake4 commented Feb 29, 2024

Sorry for the delay on this. Please revert this commit as it is no longer necessary due to the fixes I made in v0.7.6. Otherwise everything looks great now!

@Noobware1
Copy link
Contributor Author

done

@ethanblake4 ethanblake4 merged commit f08ac04 into ethanblake4:master Mar 1, 2024
1 check passed
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