-
Notifications
You must be signed in to change notification settings - Fork 928
Browser Extension Check for Analytics Module #3555
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
Changes from 3 commits
6b7d74d
54bf23b
0e1ebee
1e1f46c
257e091
c838391
bbfe8a6
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@firebase/analytics": minor | ||
--- | ||
|
||
Browser Extension Check for Analytics Module | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you make it a bit more specific? Something like: There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you add |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,7 +25,8 @@ export const enum AnalyticsError { | |
INTEROP_COMPONENT_REG_FAILED = 'interop-component-reg-failed', | ||
INDEXED_DB_UNSUPPORTED = 'indexedDB-unsupported', | ||
INVALID_INDEXED_DB_CONTEXT = 'invalid-indexedDB-context', | ||
COOKIES_NOT_ENABLED = 'cookies-not-enabled' | ||
COOKIES_NOT_ENABLED = 'cookies-not-enabled', | ||
INVALID_ANALYTICS_CONTEXT = 'invalid-analytics-context' | ||
} | ||
|
||
const ERRORS: ErrorMap<AnalyticsError> = { | ||
|
@@ -50,7 +51,9 @@ const ERRORS: ErrorMap<AnalyticsError> = { | |
'Wrap initialization of analytics in analytics.isSupported() ' + | ||
'to prevent initialization in unsupported environments', | ||
[AnalyticsError.COOKIES_NOT_ENABLED]: | ||
'Cookies are not enabled in this browser environment. Analytics requires cookies to be enabled.' | ||
'Cookies are not enabled in this browser environment. Analytics requires cookies to be enabled.', | ||
[AnalyticsError.INVALID_ANALYTICS_CONTEXT]: | ||
'Analytics module is not supported in browser extensions environemnt.' | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. How about |
||
}; | ||
|
||
interface ErrorParams { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is a patch change since we are not changing the API surface.