Sign Up for Free

RunKit +

Try any Node.js package right in your browser

This is a playground to test code. It runs a full Node.js environment and already has all of npm’s 400,000 packages pre-installed, including react-router-dom with all npm packages installed. Try it out:

require("react/package.json"); // react is a peer dependency. var reactRouterDom = require("react-router-dom")

This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.

react-router-dom v4.2.2

DOM bindings for React Router

react-router-dom

DOM bindings for React Router.

Installation

Using npm:

$ npm install --save react-router-dom

Then with a module bundler like webpack, use as you would anything else:

// using ES6 modules
import { BrowserRouter, Route, Link } from 'react-router-dom'

// using CommonJS modules
var BrowserRouter = require('react-router-dom').BrowserRouter
var Route = require('react-router-dom').Route
var Link = require('react-router-dom').Link

The UMD build is also available on unpkg:

<script src="https://unpkg.com/react-router-dom/umd/react-router-dom.min.js"></script>

You can find the library on window.ReactRouterDOM.

Issues

If you find a bug, please file an issue on our issue tracker on GitHub.

Credits

React Router is built and maintained by React Training.

Metadata

RunKit is a free, in-browser JavaScript dev environment for prototyping Node.js code, with every npm package installed. Sign up to share your code.
Sign Up for Free