[next] Embed: Defer login/logout until ready (#2123)

* feat: Embed defer login/-out until ready

* fix: make remove work with lazy render

* fix: typo

* fix: another typo

* fix: test

* chore: replace query-string for querystringify

* fix: types

* chore: small refactor

* feat: added webpack analzyer

* chore: rename compile -> generate

* fix: fix scripts and improve bundle size

* fix: lodash webpack plugin
This commit is contained in:
Kiwi
2018-12-15 00:07:09 +00:00
committed by Wyatt Johnson
parent 6f538d3235
commit 097294909b
42 changed files with 531 additions and 280 deletions
+2 -2
View File
@@ -1,6 +1,6 @@
import qs from "query-string";
import { commitLocalUpdate, Environment } from "relay-runtime";
import { parseQuery } from "talk-common/utils";
import {
createAndRetain,
LOCAL_ID,
@@ -18,7 +18,7 @@ export default async function initLocalState(environment: Environment) {
const localRecord = createAndRetain(environment, s, LOCAL_ID, LOCAL_TYPE);
// Parse query params
const query = qs.parse(location.search);
const query = parseQuery(location.search);
// Set default view.
localRecord.setValue(query.view || "SIGN_IN", "view");