Skip to content

Commit 15136c3

Browse files
committed
UI refactor
1 parent f745b9c commit 15136c3

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+2945
-2078
lines changed

.eslintrc.js

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
module.exports = {
2-
extends: ['standard', "standard-react", 'prettier'],
2+
extends: ['standard', 'prettier'],
33
plugins: ['prettier'],
44
rules: {
5-
'react/react-in-jsx-scope': 'off',
6-
'react/prop-types': 'off',
75
'prettier/prettier': [
86
'error',
97
{

.npmignore

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
1-
src
2-
front
1+
src

CHANGELOG.md

+10-8
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
11
# Change Log
22

3-
## Unreleased
3+
## 0.8.0
44

55
* Create empty `conf.json` if it doesn't exist
6-
* Update UI to open links in new tabs (should improve integration with third-party tools)
7-
* Local self-signed certicate are now generated in `~/.hotel` (you'll need to trust the certificate again)
8-
6+
* Self-signed certicate are now generated in `~/.hotel` (you'll need to "trust" the certificate again)
7+
* Update UI
8+
* New style
9+
* Drop IE support for the UI
10+
* Links now open in new tabs (should improve integration with third-party tools)
911

1012
## 0.7.6
1113

@@ -159,7 +161,7 @@ __Breaking__
159161

160162
## 0.4.12
161163

162-
* Add wildcard subdomains `http://*.app.dev`.
164+
* Add wildcard subdomains `http://*.app.localhost`.
163165

164166
## 0.4.11
165167

@@ -182,7 +184,7 @@ __Breaking__
182184
## 0.4.7
183185

184186
* Bundle front-end dependencies to make homepage work without network access.
185-
* Support subdomains `http://sub.app.dev`.
187+
* Support subdomains `http://sub.app.localhost`.
186188
* Support `https` and `wss`.
187189

188190
## 0.4.6
@@ -202,8 +204,8 @@ __Breaking__
202204

203205
## 0.4.1
204206

205-
* Added WebSocket support for projects being accessed using local `.dev` domain.
207+
* Added WebSocket support for projects being accessed using local `.localhost` domain.
206208

207209
## 0.4.0
208210

209-
* Added Local `.dev` domain support for HTTP requests.
211+
* Added Local `.localhost` domain support for HTTP requests.

README.md

+16-14
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ Development of Hotel is generously supported by contributions from people. If yo
2626

2727
## Features
2828

29-
* __Local domains__ - `http://project.dev`
30-
* __HTTPS via local self-signed certificate__ - `https://project.dev`
31-
* __Wildcard subdomains__ - `http://*.project.dev`
29+
* __Local domains__ - `http://project.localhost`
30+
* __HTTPS via local self-signed certificate__ - `https://project.localhost`
31+
* __Wildcard subdomains__ - `http://*.project.localhost`
3232
* __Works everywhere__ - OS X, Linux and Windows
3333
* __Works with any server__ - Node, Ruby, PHP, ...
3434
* __Proxy__ - Map local domains to remote servers
@@ -55,7 +55,7 @@ You can also visit https://nodejs.org.
5555

5656
### Local dev domains (optional)
5757

58-
To use local `.dev` domains, you need to configure your network or browser to use hotel's proxy auto-config file or you can skip this step for the moment and go directly to http://localhost:2000
58+
To use local `.localhost` domains, you need to configure your network or browser to use hotel's proxy auto-config file or you can skip this step for the moment and go directly to http://localhost:2000
5959

6060
[__See instructions here__](https://github.com/typicode/hotel/blob/master/docs/README.md).
6161

@@ -68,7 +68,7 @@ Add your servers commands
6868
~/projects/two$ hotel add 'serve -p $PORT'
6969
```
7070

71-
Go to [localhost:2000](http://localhost:2000) or [hotel.dev](http://hotel.dev).
71+
Go to [localhost:2000](http://localhost:2000) or [hotel.localhost](http://hotel.localhost).
7272

7373
Alternatively you can directly go to
7474

@@ -78,13 +78,13 @@ http://localhost:2000/two
7878
```
7979

8080
```
81-
http://one.dev
82-
http://two.dev
81+
http://one.localhost
82+
http://two.localhost
8383
```
8484

8585
```
86-
https://one.dev
87-
https://two.dev
86+
https://one.localhost
87+
https://two.localhost
8888
```
8989

9090
__Tip__ you can also use `hotel run <cmd>` to start your server in the terminal and get a temporary local domain.
@@ -120,8 +120,8 @@ Add your remote servers
120120
You can now access them using
121121

122122
```sh
123-
http://aliased-address.dev # will proxy requests to http://192.168.1.12:1337
124-
http://aliased-domain.dev # will proxy requests to http://google.com
123+
http://aliased-address.localhost # will proxy requests to http://192.168.1.12:1337
124+
http://aliased-domain.localhost # will proxy requests to http://google.com
125125
```
126126

127127
## CLI usage and options
@@ -172,7 +172,7 @@ hotel add "cmd -p %PORT%" # Windows
172172

173173
## Fallback URL
174174

175-
If you're offline or can't configure your browser to use `.dev` domains, you can __always__ access your local servers by going to [localhost:2000](http://localhost:2000).
175+
If you're offline or can't configure your browser to use `.localhost` domains, you can __always__ access your local servers by going to [localhost:2000](http://localhost:2000).
176176

177177
## Configurations, logs and certificates
178178

@@ -194,7 +194,9 @@ By default, `hotel` uses the following configuration values:
194194
"port": 2000,
195195
"host": '127.0.0.1',
196196
"timeout": 5000,
197-
"tld": 'dev',
197+
// Change this if you want to use another tld than .localhost
198+
"tld": 'dev',
199+
// If you're behind a corporate proxy, replace this with your network proxy IP (example: "1.2.3.4:5000")
198200
"proxy": false
199201
}
200202
```
@@ -236,7 +238,7 @@ hotel add --http-proxy-env 'server-cmd'
236238
hotel add --change-origin 'https://jsonplaceholder.typicode.com'
237239
```
238240

239-
_When proxying to a `https` server, you may get an error because your local `.dev` domain doesn't match the host defined in the server certificate. With this flag, `host` header is changed to match the target URL._
241+
_When proxying to a `https` server, you may get an error because your local `.localhost` domain doesn't match the host defined in the server certificate. With this flag, `host` header is changed to match the target URL._
240242

241243
#### `ENOSPC` and `EACCES` errors
242244

docs/README.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
1-
# Configuring local .dev domains
1+
# Configuring local .localhost domains
22

33
_This step is totally optional and you can use hotel without it._
44

5-
To use local `.dev` domain, you need to configure your browser or network to use hotel's proxy auto-config file which is available at `http://localhost:2000/proxy.pac` [[view file content](../src/daemon/views/proxy-pac.pug)].
5+
To use local `.localhost` domain, you need to configure your browser or network to use hotel's proxy auto-config file which is available at `http://localhost:2000/proxy.pac` [[view file content](../src/daemon/views/proxy-pac.pug)].
66

7-
__Important__ hotel MUST be running before configuring your network or browser so that `http://localhost:2000/proxy.pac` is available. If hotel is started after and you can't access `.dev` domains, simply disable/enable network or restart browser.
7+
__Important__ hotel MUST be running before configuring your network or browser so that `http://localhost:2000/proxy.pac` is available. If hotel is started after and you can't access `.localhost` domains, simply disable/enable network or restart browser.
88

99
## Configuring another .tld
1010

11-
You can edit `~/.hotel/conf.json` to use another Top-level Domain than `.dev`.
11+
You can edit `~/.hotel/conf.json` to use another Top-level Domain than `.localhost`.
1212

1313
```json
1414
{

nodemon.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"exec": "babel-node",
33
"ignore": [
4-
"src/front/**/*",
4+
"src/app/**/*",
55
"src/daemon/public/**/*"
66
]
77
}

0 commit comments

Comments
 (0)