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

Create package for Laravel Nova #117

Open
chrillep opened this issue Dec 9, 2021 · 2 comments
Open

Create package for Laravel Nova #117

chrillep opened this issue Dec 9, 2021 · 2 comments

Comments

@chrillep
Copy link

chrillep commented Dec 9, 2021

How would one use this with Laravel Nova?

https://nova.laravel.com/docs/3.0/installation.html#error-reporting
rollbar/rollbar-php#415

@bishopb
Copy link

bishopb commented Dec 10, 2021

Hello! Thanks for asking, @chrillep. The ideal way would be for us to provide a Nova-specific service provider and a simple set of instructions for activating that provider. That would be done under Issue #415. We are making a push right now on all Laravel derivatives, like Lumen and Zero, and I will press for a Nova integration as well.

Anyhow, in the meanwhile, you need a ServiceProvider with two methods: boot and register. The boot method will initialize Rollbar, via Rollbar::init() with your specific configuration. The register method will call Nova::report, and in the function that it takes, call Rollbar::logger()->log($exception).

Let me know if you need further details on that. Additionally, if you'd like to post a PR, those are welcome as well. I'm closing this for now, as the work to do it will be under Issue #415, but feel free to re-open to continue this conversation.

@bishopb
Copy link

bishopb commented Dec 10, 2021

Correction to my previous comment: I mistakenly thought Issue #415 was in this repo, it's not. This is the better repo for this conversation, so reopening and making this a feature request.

@bishopb bishopb reopened this Dec 10, 2021
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