This repository has been archived by the owner on Jun 12, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
2 additions
and
54 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,55 +1,3 @@ | ||
# web-base | ||
Use this to start other web projects. It gives you a good base to start from including | ||
+ has an .editorconfig to enforce typographic style like tabs instead of spaces and no trailing whitespace | ||
+ uses eslint to enforce javascript coding conventions such as no `var`s perfer arrow functions, etc | ||
+ compiles es6 using babel and webpack (includes sourcemaps) | ||
+ compiles jade -> html or strings (.tpl) | ||
+ compiles sass -> css adding browser specific prefixes where necessary | ||
# thr33 | ||
|
||
## New projects | ||
First create a new repository on [github](https://github.com/new) | ||
``` | ||
git clone [email protected]:jplikesbikes/web-base.git newrepos | ||
cd newrepos | ||
git remote rename origin upstream | ||
git remote add origin [email protected]:jplikesbikes/newrepos | ||
git push -u origin master | ||
``` | ||
Update the package.json name and repository. | ||
Update the readme. | ||
Your good to go! | ||
|
||
## Develop | ||
``` | ||
npm install | ||
npm test // run tests | ||
npm run linter // lint and auto fix formatting errors | ||
npm run web-test // run tests in browser with webpack-dev-server | ||
open localhost:8080/test.bundle | ||
npm run server // run webpack-dev-server with hot module reloading | ||
open localhost:8080 | ||
``` | ||
|
||
### Environments | ||
The `webpack.config.js` adds an `environment` module alias to a file in the `env` directory. | ||
By default, it points to `env/localhost.js`, but you can point to any file in | ||
`env` by | ||
providing a `--env environmentName` command line arg: | ||
``` | ||
#Compile with import env from `environment` pointing to `env/prod.js` | ||
npm run compiler -- --env prod | ||
``` | ||
|
||
Watching Tests | ||
``` | ||
npm test -- --watch | ||
``` | ||
|
||
Compile into `bin` and deploy to s3 | ||
``` | ||
npm run compiler | ||
npm run aws-deploy s3://your-bucket-here | ||
``` | ||
note you need the aws cli installed for deployment to work | ||
I don't know. Playing around with three.js I guess. |