Client implementation for Office Maker.
URL | |
---|---|
/ | top page |
/#floorId | specific floor page |
/?q=foo&edit=&object=#floorId | specific floor page with some conditions |
/login | login page |
/master | master page |
$ elm-package install
$ npm install
$ cp op/config-template.json config.stg.json
config.${env}.json
is configuration for stg
environment.
$ sh build.sh ${env}
- convert Elm code into JavaScript
- copy CSS files
- generate HTML
$ node watch
This automatically runs sh build.sh stg
if any file is changed. It also run static server on http://localhost:3030
.
Note: You might need to disable CORS if server returns specific Access-Control-Allow-Origin
.
Chrome 60 on Windows
$ start chrome http://localhost:3030 --disable-web-security --user-data-dir="%UserProfile%\AppData\Local\Google\Chrome\User Data"
Chrome 60 on Ubuntu
$ google-chrome http://localhost:3030 --disable-web-security --user-data-dir=/tmp/someDir
$ sh deploy.sh ${env}
Edit config.${env}.json
. Bold properties are essential to work with various environment.
name | |
---|---|
title | This name will be used by header. |
accountServiceRoot | URL of account service. http://xxx.xxx.xx.xx/accounts/api |
profileServiceRoot | URL of profile service. http://xxx.xxx.xx.xx/profiles/api |
apiRoot | URL of api server. http://xxx.xxx.xx.xx/api |
cacheRoot | Cached objects are fetched from this URL. http://xxx.xxx.xx.xx/cache |
imageRoot | Uploaded images are fetched from this URL. http://xxx.xxx.xx.xx/images |
region | S3 region you want to deploy static files to. |
s3Bucket | S3 bucket you want to deploy static files to. |
© 2017-Present WorksApplications CO.,LTD.