Skip to content
This repository was archived by the owner on Oct 26, 2018. It is now read-only.

Commit eecf670

Browse files
committed
Rename things to react-router-redux! Exciting!
1 parent 0574e4d commit eecf670

File tree

9 files changed

+38
-39
lines changed

9 files changed

+38
-39
lines changed

CHANGELOG.md

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
## [HEAD](https://github.com/rackt/redux-simple-router/compare/2.0.4...master)
1+
## [HEAD](https://github.com/rackt/react-router-redux/compare/2.0.4...master)
22

3-
- Export action creators as individual functions. [#225](https://github.com/rackt/redux-simple-router/pull/225)
3+
- Export action creators as individual functions. [#225](https://github.com/rackt/react-router-redux/pull/225)
44

5-
## [2.0.4](https://github.com/rackt/redux-simple-router/compare/2.0.2...2.0.4)
5+
## [2.0.4](https://github.com/rackt/react-router-redux/compare/2.0.2...2.0.4)
66

7-
- Remove `history` module published within the tarball. [#133](https://github.com/rackt/redux-simple-router/issues/133)
8-
- Make actions conform to [Flux Standard Action](https://github.com/acdlite/flux-standard-action). [#208](https://github.com/rackt/redux-simple-router/pull/208)
7+
- Remove `history` module published within the tarball. [#133](https://github.com/rackt/react-router-redux/issues/133)
8+
- Make actions conform to [Flux Standard Action](https://github.com/acdlite/flux-standard-action). [#208](https://github.com/rackt/react-router-redux/pull/208)
99

10-
## [2.0.2](https://github.com/rackt/redux-simple-router/compare/1.0.2...2.0.2)
10+
## [2.0.2](https://github.com/rackt/react-router-redux/compare/1.0.2...2.0.2)
1111

1212
Versions 2.0.0 and 2.0.1 were test releases for the 2.* series. 2.0.2 is the first public release.
1313

@@ -19,18 +19,18 @@ Versions 2.0.0 and 2.0.1 were test releases for the 2.* series. 2.0.2 is the fir
1919
* `UPDATE_PATH` is now `UPDATE_LOCATION`.
2020
* The fully parsed [location object](https://github.com/rackt/history/blob/master/docs/Location.md) is now stored in the state instead of a URL string. To access the path, use `state.routing.location.pathname` instead of `state.routing.path`.
2121

22-
[View the new docs](https://github.com/rackt/redux-simple-router#api)
22+
[View the new docs](https://github.com/rackt/react-router-redux#api)
2323

24-
## [1.0.2](https://github.com/rackt/redux-simple-router/compare/1.0.1...1.0.2)
24+
## [1.0.2](https://github.com/rackt/react-router-redux/compare/1.0.1...1.0.2)
2525

2626
* Only publish relevant files to npm
2727

28-
## [1.0.1](https://github.com/rackt/redux-simple-router/compare/1.0.0...1.0.1)
28+
## [1.0.1](https://github.com/rackt/react-router-redux/compare/1.0.0...1.0.1)
2929

3030
* Solve problem with `basename` causing infinite redirects (#103)
3131
* Switched to ES6 imports/exports internally, but should not affect outside users
3232

33-
## [1.0.0](https://github.com/rackt/redux-simple-router/compare/0.0.10...1.0.0)
33+
## [1.0.0](https://github.com/rackt/react-router-redux/compare/0.0.10...1.0.0)
3434
> 2015-12-09
3535
3636
This release changes quite a bit so you'll have to update your code.

README.md

+12-12
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# redux-simple-router
1+
# react-router-redux
22

3-
[![npm version](https://img.shields.io/npm/v/redux-simple-router.svg?style=flat-square)](https://www.npmjs.com/package/redux-simple-router) [![npm downloads](https://img.shields.io/npm/dm/redux-simple-router.svg?style=flat-square)](https://www.npmjs.com/package/redux-simple-router) [![build status](https://img.shields.io/travis/rackt/redux-simple-router/master.svg?style=flat-square)](https://travis-ci.org/rackt/redux-simple-router)
3+
[![npm version](https://img.shields.io/npm/v/react-router-redux.svg?style=flat-square)](https://www.npmjs.com/package/react-router-redux) [![npm downloads](https://img.shields.io/npm/dm/react-router-redux.svg?style=flat-square)](https://www.npmjs.com/package/react-router-redux) [![build status](https://img.shields.io/travis/rackt/react-router-redux/master.svg?style=flat-square)](https://travis-ci.org/rackt/react-router-redux)
44

55
**Let react-router do all the work** :sparkles:
66

@@ -11,18 +11,18 @@ react-router does a great job of mapping the current URL to a component tree, an
1111
The entire state that we are interested in boils down to one thing: the URL. This is an extremely simple library that just puts the URL in redux state and keeps it in sync with any react-router changes. Additionally, you can change the URL via redux and react-router will change accordingly.
1212

1313
```
14-
npm install redux-simple-router
14+
npm install react-router-redux
1515
```
1616

17-
If you want to install the next major version, use `redux-simple-router@next`. Run `npm dist-tag ls redux-simple-router` to see what `next` is aliased to.
17+
If you want to install the next major version, use `react-router-redux@next`. Run `npm dist-tag ls react-router-redux` to see what `next` is aliased to.
1818

19-
View the [CHANGELOG](https://github.com/rackt/redux-simple-router/blob/master/CHANGELOG.md) for recent changes.
19+
View the [CHANGELOG](https://github.com/rackt/react-router-redux/blob/master/CHANGELOG.md) for recent changes.
2020

2121
Read the [API docs](#api) farther down this page.
2222

2323
##### _What about redux-router?_
2424

25-
[redux-router](https://github.com/rackt/redux-router) is another project which solves the same problem. However, it's far more complex. Take a quick look at [the code for this library](https://github.com/rackt/redux-simple-router/blob/master/src/index.js)—it's extremely minimal. redux-router is much bigger and more complex.
25+
[redux-router](https://github.com/rackt/redux-router) is another project which solves the same problem. However, it's far more complex. Take a quick look at [the code for this library](https://github.com/rackt/react-router-redux/blob/master/src/index.js)—it's extremely minimal. redux-router is much bigger and more complex.
2626

2727
That said, redux-router is a fine project and has features this doesn't provide. Use it if you like it better.
2828

@@ -36,7 +36,7 @@ That said, redux-router is a fine project and has features this doesn't provide.
3636

3737
The idea of this library is to use react-router's functionality exactly like its documentation tells you to. You can access all of its APIs in routing components. Additionally, you can use redux like you normally would, with a single app state.
3838

39-
[redux](https://github.com/rackt/redux) (`store.routing`)  ↔  [**redux-simple-router**](https://github.com/rackt/redux-simple-router)  ↔  [history](https://github.com/rackt/history) (`history.location`)  ↔  [react-router](https://github.com/rackt/react-router)
39+
[redux](https://github.com/rackt/redux) (`store.routing`)  ↔  [**react-router-redux**](https://github.com/rackt/react-router-redux)  ↔  [history](https://github.com/rackt/history) (`history.location`)  ↔  [react-router](https://github.com/rackt/react-router)
4040

4141
We only store current URL and state, whereas redux-router stores the entire location object from react-router. You can read it, and also change it with an action.
4242

@@ -52,7 +52,7 @@ import ReactDOM from 'react-dom'
5252
import { createStore, combineReducers, applyMiddleware } from 'redux'
5353
import { Provider } from 'react-redux'
5454
import { Router, Route, browserHistory } from 'react-router'
55-
import { syncHistory, routeReducer } from 'redux-simple-router'
55+
import { syncHistory, routeReducer } from 'react-router-redux'
5656
import reducers from '<project-path>/reducers'
5757

5858
const reducer = combineReducers(Object.assign({}, reducers, {
@@ -84,7 +84,7 @@ ReactDOM.render(
8484
Now you can read from `state.routing.location.pathname` to get the URL. It's far more likely that you want to change the URL more often, however. You can use the `push` action creator that we provide:
8585

8686
```js
87-
import { routeActions } from 'redux-simple-router'
87+
import { routeActions } from 'react-router-redux'
8888

8989
function MyComponent({ dispatch }) {
9090
return <Button onClick={() => dispatch(routeActions.push('/foo'))}/>;
@@ -94,7 +94,7 @@ function MyComponent({ dispatch }) {
9494
This will change the state, which will trigger a change in react-router. Additionally, if you want to respond to the path update action, just handle the `UPDATE_LOCATION` constant that we provide:
9595

9696
```js
97-
import { UPDATE_LOCATION } from 'redux-simple-router'
97+
import { UPDATE_LOCATION } from 'react-router-redux'
9898

9999
function update(state, action) {
100100
switch(action.type) {
@@ -106,7 +106,7 @@ function update(state, action) {
106106

107107
### Examples
108108

109-
* [examples/basic](https://github.com/rackt/redux-simple-router/blob/master/examples/basic) - basic reference implementation
109+
* [examples/basic](https://github.com/rackt/react-router-redux/blob/master/examples/basic) - basic reference implementation
110110

111111
Examples from the community:
112112

@@ -121,7 +121,7 @@ Examples from the community:
121121
* [StevenIseki/redux-simple-router-example](https://github.com/StevenIseki/redux-simple-router-example)
122122
* [mattkrick/meatier](https://github.com/mattkrick/meatier) - SSR, dual dev/prod client builds
123123
* [mxstbr/react-boilerplate](https://github.com/mxstbr/react-boilerplate/tree/v3.0.0) - :fire: Quick setup for performance orientated, offline first React.js applications
124-
* **Tip**: Upgrading from react-router w/o redux-simple-router? Use [this PR](https://github.com/mxstbr/react-boilerplate/pull/98/files) as a reference!
124+
* **Tip**: Upgrading from react-router w/o react-router-redux? Use [this PR](https://github.com/mxstbr/react-boilerplate/pull/98/files) as a reference!
125125

126126
_Have an example to add? Send us a PR!_
127127

examples/basic/README.md

+8-9
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,27 @@
1-
redux-simple-router basic example
1+
react-router-redux basic example
22
=================================
33

44
This is a basic example that demonstrates rendering components based
55
on URLs with `react-router` as well as connecting them to Redux state.
6-
It uses both <Link> elements as well as the `push` action creator
7-
provided by redux-simple-router.
6+
It uses both <Link> elements as well as the `push` action creator
7+
provided by react-router-redux.
88

9-
This example also demonstrates integration with
9+
This example also demonstrates integration with
1010
**[redux-devtools](https://github.com/gaearon/redux-devtools) ^3.0.0**
1111

1212
**To run, follow these steps:**
1313

1414
1. Install dependencies with `npm install` in this directory (make sure it creates a local node_modules)
15-
2. By default, it uses the local version from `src` of redux-simple-router, so you need to run `npm install` from there first. If you want to use a version straight from npm, remove the lines in `webpack.config.js` at the bottom.
15+
2. By default, it uses the local version from `src` of react-router-redux, so you need to run `npm install` from there first. If you want to use a version straight from npm, remove the lines in `webpack.config.js` at the bottom.
1616
3. Build with `webpack --watch`
1717
4. Open `index.html`
1818

1919
-
2020

21-
If you want to run the example from the npm published version of
22-
**redux-simple-router**, remove the alias in `webpack.config`
21+
If you want to run the example from the npm published version of
22+
**react-router-redux**, remove the alias in `webpack.config`
2323
to the source from line 21.
2424

2525
This example uses the latest version, switch to a specific tag to use a stable version:
2626

27-
e.g. [redux-simple-router tag 1.0.2](https://github.com/rackt/redux-simple-router/tree/1.0.2/examples/basic)
28-
27+
e.g. [react-router-redux tag 1.0.2](https://github.com/rackt/react-router-redux/tree/1.0.2/examples/basic)

examples/basic/app.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import { applyMiddleware, compose, createStore, combineReducers } from 'redux'
88
import { Provider } from 'react-redux'
99
import { Router, Route, IndexRoute } from 'react-router'
1010
import createHistory from 'history/lib/createHashHistory'
11-
import { syncHistory, routeReducer } from 'redux-simple-router'
11+
import { syncHistory, routeReducer } from 'react-router-redux'
1212

1313
import * as reducers from './reducers'
1414
import { App, Home, Foo, Bar } from './components'

examples/basic/components/App.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React from 'react'
22
import { Link } from 'react-router'
33
import { connect } from 'react-redux'
4-
import { routeActions } from 'redux-simple-router'
4+
import { routeActions } from 'react-router-redux'
55

66
function App({ push, children }) {
77
return (

examples/basic/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<!DOCTYPE html>
22
<html>
33
<head>
4-
<title>redux-simple-router basic example</title>
4+
<title>react-router-redux basic example</title>
55
<meta charset="utf8"/>
66
</head>
77
<body>

examples/basic/package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "rsr-basic-example",
33
"version": "0.0.0",
4-
"repository": "rackt/redux-simple-router",
4+
"repository": "rackt/react-router-redux",
55
"license": "MIT",
66
"dependencies": {
77
"history": "^1.14.0",
@@ -10,7 +10,7 @@
1010
"react-redux": "^4.0.0",
1111
"react-router": "^1.0.0",
1212
"redux": "^3.0.4",
13-
"redux-simple-router": "^2.0.3"
13+
"react-router-redux": "^2.1.0"
1414
},
1515
"devDependencies": {
1616
"babel-core": "^6.1.21",

examples/basic/webpack.config.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ var src = path.join(__dirname, '..', '..', 'src')
2626
var fs = require('fs')
2727
if (fs.existsSync(src)) {
2828
// Use the latest src
29-
module.exports.resolve = { alias: { 'redux-simple-router': src } }
29+
module.exports.resolve = { alias: { 'react-router-redux': src } }
3030
module.exports.module.loaders.push({
3131
test: /\.js$/,
3232
loaders: ['babel'],

package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "redux-simple-router",
2+
"name": "react-router-redux",
33
"version": "2.0.4",
44
"description": "Ruthlessly simple bindings to keep react-router and redux in sync",
55
"main": "lib/index",
@@ -9,7 +9,7 @@
99
"lib",
1010
"src"
1111
],
12-
"repository": "rackt/redux-simple-router",
12+
"repository": "rackt/react-router-redux",
1313
"authors": [
1414
"James Long"
1515
],

0 commit comments

Comments
 (0)