interface: document HMR

This commit is contained in:
Liam Fitzgerald 2020-07-15 15:15:41 +10:00
parent 09375d311d
commit 5ba1027a90
2 changed files with 19 additions and 1 deletions

View File

@ -88,6 +88,23 @@ hygiene][contributing].
[contributing]: /CONTRIBUTING.md#git-practice [arvo]: /pkg/arvo
[interface]:/pkg/interface
### Webpack Dev Server
If you are only intending to test the JS on one ship, then you may use the
webpack dev server to allow for HMR. To do this, uncomment the `URL` property
in your urbitrc and replace it with the URL of the urbit that you are testing
on. e.g.
```javascript
module.exports = {
URL: 'http://localhost:80'
}
```
and then run `npm run start` as usual. You can then access a hot reloaded
version of the interface at `http://localhost:9000`. Note that this also works
for non-locally hosted ships.
## Linting
The Urbit interface uses Eslint to lint the JavaScript code. To install the

View File

@ -2,5 +2,6 @@ module.exports = {
URBIT_PIERS: [
"/Users/user/ships/zod/home",
],
herb: false
herb: false,
// URL: 'http://localhost:80'
};