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

allow to disable some dev errors to avoid modal disturbance #515

Closed
Tracked by #197
aralroca opened this issue Oct 4, 2024 · 1 comment · Fixed by #527
Closed
Tracked by #197

allow to disable some dev errors to avoid modal disturbance #515

aralroca opened this issue Oct 4, 2024 · 1 comment · Fixed by #527
Assignees
Labels
enhancement New feature or request

Comments

@aralroca
Copy link
Collaborator

aralroca commented Oct 4, 2024

Allow to disable some dev errors to avoid modal disturbance. Sometimes using libraries you can have errors that appear in the modal during dev but are not solvable by the client and the modal is more annoying than helpful. For these cases, it would be nice to be able to define which errors you want to ignore, example of use:

https://stackoverflow.com/questions/76187282/react-resizeobserver-loop-completed-with-undelivered-notifications/77914968#77914968

Proposal by: @enzonotario

@aralroca aralroca added the enhancement New feature or request label Oct 4, 2024
@aralroca aralroca changed the title Disable some dev errors to avoid modal disturbance allow to disable some dev errors to avoid modal disturbance Oct 4, 2024
@aralroca aralroca mentioned this issue Oct 4, 2024
26 tasks
@aralroca aralroca self-assigned this Oct 7, 2024
@aralroca
Copy link
Collaborator Author

aralroca commented Oct 7, 2024

Example on Webpack webpack/webpack-dev-server#4777

https://github.com/malcolm-kee/webpack-dev-server/blob/f7386f60da170b158d13a2c41cc668f0b83d9679/client-src/index.js#L50-L54

It seems that there is no other way than passing the function in string and executing it on the client. The downsides of this:

  • You can't use external variables inside the function.
  • You cannot generate side-effects outside the function.

If this is the only option, we can do it this way. I will investigate a little bit to see if there is the possibility to separate inside brisa.config.ts the client code with server code to make a bundle of this. It would also solve the i18n formatters in the client.

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

Successfully merging a pull request may close this issue.

1 participant