Augment react-router module with react-router-relay typings

前端 未结 2 951
礼貌的吻别
礼貌的吻别 2021-02-19 02:40

The default react-router is used as such:

import * as React from \'react\';
import { Router, Route, hashHistory } from \'react-router\';

const routing = (
    &         


        
2条回答
  •  滥情空心
    2021-02-19 03:04

    Try this one

    declare module 'react-router' { 
       interface RouterProps {
          environment?: any
          render?: any
       } 
    }
    

    it's working with the latest react-router definitions.

提交回复
热议问题