Class: WebpackDriver::DevServer
- Defined in:
- lib/webpack_driver/dev_server.rb
Overview
A wrapper around an instance of ‘webpak-dev-server`
Constant Summary
Constants inherited from Process
Instance Attribute Summary collapse
-
#host ⇒ Object
readonly
Returns the value of attribute host.
-
#path ⇒ Object
readonly
Returns the value of attribute path.
-
#port ⇒ Object
readonly
Returns the value of attribute port.
Attributes inherited from Process
#assets, #config, #error, #last_compilation_message, #last_status, #messages
Instance Method Summary collapse
-
#initialize(config) ⇒ DevServer
constructor
A new instance of DevServer.
- #valid? ⇒ Boolean
Methods inherited from Process
Constructor Details
#initialize(config) ⇒ DevServer
Returns a new instance of DevServer.
8 9 10 |
# File 'lib/webpack_driver/dev_server.rb', line 8 def initialize(config) super('webpack-dev-server', config) end |
Instance Attribute Details
#host ⇒ Object (readonly)
Returns the value of attribute host.
6 7 8 |
# File 'lib/webpack_driver/dev_server.rb', line 6 def host @host end |
#path ⇒ Object (readonly)
Returns the value of attribute path.
6 7 8 |
# File 'lib/webpack_driver/dev_server.rb', line 6 def path @path end |
#port ⇒ Object (readonly)
Returns the value of attribute port.
6 7 8 |
# File 'lib/webpack_driver/dev_server.rb', line 6 def port @port end |
Instance Method Details
#valid? ⇒ Boolean
12 13 14 |
# File 'lib/webpack_driver/dev_server.rb', line 12 def valid? alive? && last_status == 'success' end |