main
Last change
on this file since 8d83180 was 6221ab6, checked in by unknown <mlviktor23@…>, 2 years ago |
finished add post func. in react, fixed user dashboard details not loading upon login redirect
|
-
Property mode
set to
100644
|
File size:
526 bytes
|
Line | |
---|
1 | import React, { useState, useEffect } from "react";
|
---|
2 | import JSOG from "jsog";
|
---|
3 | import axios from "../api/axios";
|
---|
4 | import Logout from "./Logout";
|
---|
5 |
|
---|
6 | function UserHeader({ user, userLoaded }) {
|
---|
7 | return userLoaded ? (
|
---|
8 | <div style={{ float: "left", marginTop: 20, marginLeft: 40 }}>
|
---|
9 | Најавен/а: <a href="/user_dashboard">{user.username}</a> <Logout />{" "}
|
---|
10 | </div>
|
---|
11 | ) : (
|
---|
12 | <div style={{ float: "left", marginTop: 25, marginLeft: 60 }}>
|
---|
13 | се вчитува...
|
---|
14 | </div>
|
---|
15 | );
|
---|
16 | }
|
---|
17 |
|
---|
18 | export default UserHeader;
|
---|
Note:
See
TracBrowser
for help on using the repository browser.