command
module
Version:
v0.0.0-...-acccb75
Opens a new window with list of versions in this module.
Published: Feb 24, 2016
License: MIT
Opens a new window with license information.
Imports: 5
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
¶
web-starter-kit
Use Go, Webpack to build and package web application starter kit.
- Use sweb to make web server
- Use webpack to package all the frontend assets
- Use webpack-dev-server to support HMR
- Depends on GNU Make and fswatch
Demo:
- Use material-design-lite SCSS version as the basic style templates and customize the color and themes
- Use React to build a MDL Component button
- run
make dev
to start a local development watcher, auto watch assets change and go code change, restart the go web server
- run
make dist
to create distribution packages, including all the assets, templates and binary which can be deployed
- A
DemoApi
controller rendering JSON response
- A
DemoController
controller rendering HTML response using templates
Big thanks to:
- go-starter-kit
- Webpack your bags
- react-transform-hmr
- babel-preset-react-hmre
Hot module reload
See webpack-dev-server doc
GO Web Server
should render all aseets with prefix the dev-server domain http://localhost:8000
- As config in
webpack.config.js
, all the request (except the hot-update ones ) is proxied to GO web Server
Missing Parts:
- Sprite images management and auto-generation
- Config the port of both Go Web Server and webpack-dev-server, and config each one for the other
Contributions:
- acecode.tk@gmail.com for the HMR
License
MIT
Documentation
¶
There is no documentation for this package.
Source Files
¶
Directories
¶
Click to show internal directories.
Click to hide internal directories.