25 Commits

Author SHA1 Message Date
Carlos Paelinck
a73fa958df Added support for node env provide plugin. 2017-10-09 13:27:50 -05:00
Carlos Paelinck
e5bc557af4 Fix WP 3 size reporting, disable inspectpack in minimal 2017-10-04 13:08:12 -07:00
Ryan Roemer
5135858040 Add more project root inference for versions (aka Unable to find project root package.json issue) (#194)
We have a bug opened in `inspectpack` repo that is really a `webpack-dashboard` issue. Fixes https://github.com/FormidableLabs/inspectpack/issues/45

The `inspectpack` `versions` action detects versions skews in installed packages within a webpack bundle by actually traversing the `node_modules` installed from the "project root" which is basically the directory that contains the operating `package.json`.

Some bespoke webpack configurations change `bundle.context` to something _other_ than a directory that is our "project root". This causes `inspectpack` to rightfully bomb out with a `Error: Unable to find project root package.json` error -- because if you're running `versions` you need to have this accessible.

In `webpack-dashboard`-land, it pays to be a little more permissive, because folks might not mind missing `versions` for getting all the _other_ cool dashboard stuff. So, accordingly, here's how the dashboard now deals with the problem:

1. If the `DashboardPlugin` specifies a `root` option to the root project directory, we use that. **Note**: We don't _check_ it's valid -- if it's invalid and manually specified you **will** get this same error.
2. If no `root` is specified, try to see if `bundle.context` has a `package.json`, use that.
3. If `bundle.context` isn't workable, try `process.cwd()`.
4. If `process.cwd()` isn't usable, then just _disable_ the `versions` action for the dashboard.
2017-09-21 10:43:01 -07:00
Tyler Thompson
8fe3836759 Add travis 2017-09-11 21:27:40 -07:00
Tyler Thompson
03e0a4164b Upgrade inspectpack 2017-09-10 16:21:37 -07:00
Ken Wheeler
c6fe421585 moving daemon to constructor 2017-08-21 14:37:28 -04:00
Tyler Thompson
dd06bcd783 Stream actions with completion to the socket 2017-08-19 13:38:02 -07:00
Ken Wheeler
f74dbe9080 Electron fix (#178)
* making prettier

* fixing electron
2017-08-18 12:58:12 -04:00
Kevin Kerr
021f56469b close socket if not watching (#172) 2017-07-06 10:59:20 -04:00
Tyler Thompson
b067205e95 Fix busted error messages; fix percentages 2017-04-19 21:52:53 -07:00
Tyler Thompson
20b5fc15cd Don't parse sourcemaps! 2017-04-17 13:32:04 -07:00
Tyler Thompson
b6903ea03a Move inspectpack daemon to the plugin and add problem pane support 2017-04-13 17:15:55 -07:00
Tyler Thompson
dd3fa3ebf4 Use new built-in inspectpack daemon; restore version numbers; add colors and error state 2017-04-06 15:19:51 -07:00
Tyler Thompson
333c99db9d Initial pass at min+gz sizes using inspectpack 2017-03-31 15:30:41 -07:00
Tyler Thompson
c748af7747 Fix remaining lint issues and convert to node 4 ES6 2017-03-31 10:12:04 -07:00
Simon Flack
ef6cb31a42 Respect stats options from webpack config in log output (#155)
Inspired by solutions to #149 provided by @nlutterman
2017-03-24 13:29:42 -04:00
Yacine Hmito
14094fe55f Get log directly from Webpack (#143)
The plugin sends log message through the socket
If the dashboard is used as it is now, this is simply ignored
It is however printed if the user doesn't provide a command
2017-01-27 10:38:46 -05:00
Simen Bekkhus
d9d80fc304 Show millis under Operation (#140) 2017-01-02 10:03:17 -05:00
Semyon Radionov
7466622259 Add time information to Operation block (#74) 2016-08-25 20:53:03 -04:00
Dylan Markow
35e9f463a7 Switch from json-socket to socket.io
`json-socket` has issues with multibyte characters in large messages.
`socket.io` appears to be much more actively maintained and properly
supports the messages `json-socket` was having problems with.
2016-08-19 10:23:26 -05:00
Ken Wheeler
d306062cec Fixing windows & babel-node (#63)
* - Fixes windows by using cross-spawn, closes #57, #62
- Fixes babel node issue where child processes aren't killed, closes #61

* Cleaning up quotes and passing colors through

* Fixing log color output
2016-08-19 08:44:02 -04:00
Ken Wheeler
7b6e9a1904 New approach (#50)
* Separate processes

* Socket comm

* Fixing some things, adding minimal mode
2016-08-17 21:15:05 -04:00
Ken Wheeler
ed6625d018 console redirection 2016-08-15 16:52:48 -04:00
C. T. Lin
be271364c1 fix 2 spaces indent 2016-08-15 10:55:07 +08:00
Ken Wheeler
75ddff3120 Initial commit 2016-08-14 14:41:04 -04:00