Skip to content

Commit

Permalink
doc: BrowserHistory is supported, but not HashHistory
Browse files Browse the repository at this point in the history
  • Loading branch information
ZacharyRSmith committed Sep 15, 2018
1 parent 4082960 commit 638db4b
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [1.6.6] - 2018-09-15
### Added
- Note in README.md that BrowserHistory is supported, but not HashHistory

## [1.6.5] - 2018-09-02
### Added
- Demo to README.md

## [1.6.4] - 2018-07-25
### Fixed
- Only set state if mounted
Expand Down
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@

#### Overview

#### Demo

#### Example Usage

#### API
Expand All @@ -16,6 +18,8 @@

Promps user to confirm navigation. A replacement component for the react-router `<Prompt/>` (this still uses react-router to work). Allows for more flexible dialogs.

Note: Currently tested using only react-router's `BrowserHistory`. `HashHistory` has issues: https://github.com/ZacharyRSmith/react-router-navigation-prompt/issues/36

Note: Navigation away from your site, reload, or closing tab/window will also prompt navigation confirmation when `<NavigationPrompt/>`'s `props.when` is truthy. Usually, browsers handle this navigation UX themselves, leading to vanilla alert boxes. Also, many browsers require users to interact with your site before confirming navigation away.

Motivation: https://github.com/ReactTraining/react-router/issues/4635
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-router-navigation-prompt",
"version": "1.6.5",
"version": "1.6.6",
"description": "A replacement component for the react-router `<Prompt/>`. Allows for more flexible dialogs.",
"scripts": {
"build": "webpack",
Expand Down

0 comments on commit 638db4b

Please sign in to comment.