Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CSS and JS Minification and package.json update #11

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

chiho13
Copy link

@chiho13 chiho13 commented Jan 26, 2016

I think the most useful change is the ability for learners to minify main.js file, especially when they want to deploy the app. It reminds them what is good practice by keeping the total size of web app less than ~1.5 MB. It also saves a lot of initial loading time for visitors.

My Imgur Browser loads much faster first time round. Uglifier cuts JS file size by 90%.
For   "gulp-cssnano": "^2.1.0",
    "gulp-rename": "^1.2.2",
    "gulp-uglify": "^1.5.1",
@chiho13 chiho13 closed this Jan 26, 2016
@chiho13 chiho13 reopened this Jan 26, 2016
@StephenGrider
Copy link
Owner

@chiho13 This looks good, 2 comments:

  1. I'm down for this addition, but it should take the form of a new task altogether. Right now the build task is a misnomer, build is typically short for build for production, but we're using it to build the dev version of the app.
  2. Match formatting with the rest of the gulpfile, eg .pipe( gulp.dest( './' ) ); to .pipe(gulp.dest('./'));

@chiho13
Copy link
Author

chiho13 commented Jan 28, 2016

do you mean the css minification and js uglify should be one task?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants