UNPKG
react-devise-facebook-encore
Version:
latest (6.4.1)
6.4.1
A simple package to interact with Facebook LogIn API
gastongouron/react-devise-facebook-encore
react-devise-facebook-encore
/
src
/
withAuth.js
13 lines
(10 loc)
•
286 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
import
React
from
'react'
;
import
{getConfig}
from
'./config/index'
;
const
withAuth
=
WrappedComponent
=> {
const
Authorized
= props => {
const
config =
getConfig
();
return
<
WrappedComponent
auth
=
{config}
{
...props
} />
; };
return
Authorized
; };
export
default
withAuth;