Skip to content

Commit 462f69f

Browse files
committed
Make history mode configurable
1 parent 3a30178 commit 462f69f

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,12 @@ npm install
1818
CATALOG_URL=http://path/to/catalog.json npm start -- --open
1919
```
2020

21+
STAC Browser defaults to using [HTML5 History
22+
Mode](https://router.vuejs.org/guide/essentials/history-mode.html), which can
23+
cause problems on certain web hosts. To use _hash mode_, set
24+
`HISTORY_MODE=hash` when running or building. This will be compatible with
25+
S3, etc.
26+
2127
## Building
2228

2329
```bash

src/main.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ const main = async () => {
175175

176176
const router = new VueRouter({
177177
base: process.env.PATH_PREFIX || "/",
178-
mode: "history",
178+
mode: process.env.HISTORY_MODE || "history",
179179
routes
180180
});
181181

0 commit comments

Comments
 (0)