DefinitelyTyped/types/fluxible-router/index.d.ts
Max 3d4028cde1 add missing types and functions to fluxible (#28729)
* add types for package 'fluxible'

* add fluxible router types

* fix tests

* fixed annotation

* add missing types

* fix tsconfig.json

* fix for lint

* fix lint

* fix name of a package

* add missing description

* delete bad copypaste

* add test file

* add tests

* fix getStore type check
2018-10-09 10:53:16 -07:00

33 lines
1.0 KiB
TypeScript

// Type definitions for fluxible-router 1.5
// Project: https://github.com/yahoo/fluxible#readme
// Definitions by: xbim <https://github.com/xbim>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.8
/// <reference types="node" />
import * as React from 'react';
import { FluxibleContext } from 'fluxible';
import BaseStore = require('fluxible/addons/BaseStore');
export class NavLink extends React.Component<NavLinkProps, any> { }
export class RouteStore extends BaseStore {
dehydrate(context?: FluxibleContext): any;
rehydrate(state: any): void;
static withStaticRoutes(routes: object): typeof RouteStore;
}
export function handleHistory(Component: typeof React.Component, opts?: object): typeof React.Component;
export function navigateAction(context: FluxibleContext, params: object): undefined;
export class NavLinkProps {
href?: string;
routeName?: string;
activeStyle?: object;
preserveScrollPosition?: boolean;
className?: string;
type?: string;
}