Title: Bug and solution: angularfire2 auth not working with angular universal · Issue #1270 · angular/angularfire · GitHub
Open Graph Title: Bug and solution: angularfire2 auth not working with angular universal · Issue #1270 · angular/angularfire
X Title: Bug and solution: angularfire2 auth not working with angular universal · Issue #1270 · angular/angularfire
Description: Thanks for @katowulf advice. Think you found a bug? Yes, I found a bug in angular auth when running on nodejs with angular universal universal starter repo Version info @angular/ 4.2.4 firebase: 4.5.0 angularfire2: 5.0.rc-2 Steps to set ...
Open Graph Description: Thanks for @katowulf advice. Think you found a bug? Yes, I found a bug in angular auth when running on nodejs with angular universal universal starter repo Version info @angular/ 4.2.4 firebase: 4....
X Description: Thanks for @katowulf advice. Think you found a bug? Yes, I found a bug in angular auth when running on nodejs with angular universal universal starter repo Version info @angular/ 4.2.4 firebase: 4....
Opengraph URL: https://github.com/angular/angularfire/issues/1270
X: @github
Domain: github.com
IPv4 address: 140.82.113.4
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Bug and solution: angularfire2 auth not working with angular universal","articleBody":"Thanks for @katowulf advice.\r\n\r\nThink you found a bug?\r\n=======================\r\nYes, I found a bug in angular auth when running on nodejs with angular universal [universal starter repo](https://github.com/angular/universal-starter)\r\n### Version info\r\n- @angular/ 4.2.4\r\n- firebase: 4.5.0\r\n- angularfire2: 5.0.rc-2\r\n\r\n**Steps to set up and reproduce**\r\n\r\n1) clone [universal starter repo](https://github.com/angular/universal-starter)\r\n2) add firebase module to app module\r\n3) add auth in app.component.ts\r\n\r\n4) run `npm run build:dynamic && npm run serve:dynamic`\r\n5) get error\r\n\r\nI make an [sample repository](https://github.com/hiepxanh/angularfire-error.git) here to view my code\r\n\r\n### ERROR\r\n**Failing test unit, Plunkr, or JSFiddle demonstrating the problem**\r\n\r\n\r\n### Expected behavior\r\n\r\nIn my opinion, angularfire2 already have XMLHttpRequest library, but maybe some problem when bootstrap. Maybe you can fix this bug and I don't have to add XMLHttpRequest manually\r\n\r\n### Actual behavior\r\nget error with XMLHttpRequest.\r\nSolution: I add this on top, error gone. \r\n```\r\n// server.ts file\r\n(global as any).XMLHttpRequest = require(\"xmlhttprequest\").XMLHttpRequest;\r\n// your code next...\r\n\r\n```\r\n","author":{"url":"https://github.com/hiepxanh","@type":"Person","name":"hiepxanh"},"datePublished":"2017-10-15T03:30:23Z","url":"https://github.com/angular/angularfire/issues/1270"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:b83663f6-21cb-e085-858c-8714564c8daa |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B3AE:302CFA:20AA0A6:2B72935:6B03601E |
| html-safe-nonce | 6a918e046fe2d49ab1831cba1f0f867e6c787efc731f424f4d04d448b2f6acc8 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCM0FFOjMwMkNGQToyMEFBMEE2OjJCNzI5MzU6NkIwMzYwMUUiLCJ2aXNpdG9yX2lkIjoiNjM4MjIwMjM2MzMxNjM4ODE1IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 4eefe1eaa67caa0b854f7f8ce75939f5af0531b9f71c6eae6d026511e4f92c26 |
| hovercard-subject-tag | issue:265542680 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/angular/angularfire/1270/issue_layout |
| twitter:image | https://opengraph.githubassets.com/4940343bcd922b14c7661605546d29bb9834d7e5b72207bb019ee6a574c84092/angular/angularfire/issues/1270 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/4940343bcd922b14c7661605546d29bb9834d7e5b72207bb019ee6a574c84092/angular/angularfire/issues/1270 |
| og:image:alt | Thanks for @katowulf advice. Think you found a bug? Yes, I found a bug in angular auth when running on nodejs with angular universal universal starter repo Version info @angular/ 4.2.4 firebase: 4.... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | hiepxanh |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/angular/angularfire git https://github.com/angular/angularfire.git |
| octolytics-dimension-user_id | 139426 |
| octolytics-dimension-user_login | angular |
| octolytics-dimension-repository_id | 49453413 |
| octolytics-dimension-repository_nwo | angular/angularfire |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 49453413 |
| octolytics-dimension-repository_network_root_nwo | angular/angularfire |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width