This commit is contained in:
谢思 2021-09-27 11:11:32 +08:00
parent 1402029bfe
commit 295d0dbe5c
1 changed files with 3 additions and 2 deletions

View File

@ -43,13 +43,14 @@ const Infos = styled.div`
} }
`; `;
// //
export default ({ match , history }) => { export default (props) => {
const { match , history } = props;
const [data, setData] = useState({undefined}); const [data, setData] = useState({undefined});
const [commit, setCommit] = useState(undefined); const [commit, setCommit] = useState(undefined);
const [parents, setParents] = useState(undefined); const [parents, setParents] = useState(undefined);
const [committer, setCommitter] = useState(undefined); const [committer, setCommitter] = useState(undefined);
const [isSpin, setIsSpin] = useState(true); const [isSpin, setIsSpin] = useState(true);
console.log(match); console.log('----------', match , history, props);
const { sha , projectsId, owner, branchName } = match.params; const { sha , projectsId, owner, branchName } = match.params;
useEffect(() => { useEffect(() => {
if (projectsId && owner && sha) { if (projectsId && owner && sha) {