Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F32768821
landing-ssr.react.js
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
landing-ssr.react.js
View Options
// @flow
import
*
as
React
from
'react'
;
import
{
StaticRouter
}
from
'react-router'
;
import
{
type
SIWEMessageType
}
from
'lib/types/siwe-types.js'
;
import
Landing
from
'./landing.react.js'
;
import
{
SIWEContext
}
from
'./siwe-context.js'
;
export
type
LandingSSRProps
=
{
+
url
:
string
,
+
basename
:
string
,
+
siweNonce
:
?
string
,
+
siwePrimaryIdentityPublicKey
:
?
string
,
+
siweMessageType
:
?
SIWEMessageType
,
};
function
LandingSSR
(
props
:
LandingSSRProps
)
:
React
.
Node
{
const
{
url
,
basename
,
siweNonce
,
siwePrimaryIdentityPublicKey
,
siweMessageType
,
}
=
props
;
const
siweContextValue
=
React
.
useMemo
(
()
=>
({
siweNonce
,
siwePrimaryIdentityPublicKey
,
siweMessageType
,
}),
[
siweNonce
,
siwePrimaryIdentityPublicKey
,
siweMessageType
],
);
const
routerContext
=
React
.
useMemo
(()
=>
({}),
[]);
return
(
<
StaticRouter
location
=
{
url
}
basename
=
{
basename
}
context
=
{
routerContext
}
>
<
SIWEContext
.
Provider
value
=
{
siweContextValue
}
>
<
Landing
/>
<
/SIWEContext.Provider>
<
/StaticRouter>
);
}
export
default
LandingSSR
;
File Metadata
Details
Attached
Mime Type
text/x-java
Expires
Fri, Jan 9, 12:38 PM (20 h, 49 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
5868299
Default Alt Text
landing-ssr.react.js (1 KB)
Attached To
Mode
rCOMM Comm
Attached
Detach File
Event Timeline
Log In to Comment