-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Labels
BugFeature: User FeedbackPackage: nextjsIssues related to the Sentry Nextjs SDKIssues related to the Sentry Nextjs SDK
Description
Is there an existing issue for this?
- I have checked for existing issues https://github.com/getsentry/sentry-javascript/issues
- I have reviewed the documentation https://docs.sentry.io/
- I am using the latest SDK release https://github.com/getsentry/sentry-javascript/releases
How do you use Sentry?
Sentry Saas (sentry.io)
Which SDK are you using?
@sentry/nextjs
SDK Version
8.9.2
Framework Version
nextjs 14.2.2
Link to Sentry event
https://impact-as-01.sentry.io/feedback/?feedbackSlug=dagrofa-spa:1699972&project=4507299065954384
SDK Setup
No response
Steps to Reproduce
We are using the Feedback API to submit user feedback, we tried adding support for uploading images, however these do not show up correctly in Sentry.
We are converting a file to base 64 with a function like this that uses FileReader
const convertBase64 = (file: File) => {
return new Promise((resolve, reject) => {
const fileReader = new FileReader();
fileReader.onload = () => {
resolve(fileReader.result);
};
fileReader.onerror = (error) => {
reject(error);
};
fileReader.readAsDataURL(file);
});
};
It ends up like this string (concatinated):
data:image/jpeg;base64,/9j/4AAQSkZJRgABAQE....AHwAAAQ9k=
This works file when trying to view it with <img src="data-here" /> but it's not working in sentry. I'm suspecting that the docs on https://docs.sentry.io/platforms/javascript/user-feedback/#user-feedback-api is not 100% clear on the base64 expected.
Expected Result
Getting a image that's viewable in sentry.
Actual Result
alamenai
Metadata
Metadata
Labels
BugFeature: User FeedbackPackage: nextjsIssues related to the Sentry Nextjs SDKIssues related to the Sentry Nextjs SDK
Projects
Status
Waiting for: Product Owner
