olefredrik / FoundationPress

FoundationPress is a WordPress starter theme based on Foundation 6 by Zurb
https://foundationpress.olefredrik.com
MIT License
2.7k stars 867 forks source link

[Updates] Proposal for packages updates -feedback welcome- #1333

Open mattbag opened 5 years ago

mattbag commented 5 years ago

I am playing around with the packages updates, this seems to be working with:

{
  "name": "foundationpress",
  "title": "FoundationPress",
  "version": "4.65.0",
  "description": "FoundationPress is a WordPress starter theme based on Foundation 6 by Zurb",
  "homepage": "https://foundationpress.olefredrik.com",
  "license": "MIT",
  "scripts": {
    "start": "gulp",
    "dev": "gulp build --dev",
    "build": "gulp build --production",
    "package": "gulp package --production",
    "phpcs": "gulp phpcs",
    "phpcbf": "gulp phpcbf"
  },
  "keywords": [
    "FoundationPress",
    "WordPress",
    "starter theme",
    "Foundation",
    "semantic",
    "mobile first",
    "customizable",
    "responsive"
  ],
  "dependencies": {
    "chocolat": "^0.4.21",
    "foundation-sites": "^6.5.1",
    "instafeed.js": "^1.4.1",
    "jquery": ">=3.3.1",
    "motion-ui": "^2.0.3",
    "what-input": "^5.1.3"
  },
  "devDependencies": {
    "ansi-colors": "^3.2.1",
    "babel-core": "^6.26.3",
    "babel-loader": "^7.1.5",
    "babel-preset-es2015": "^6.24.1",
    "babel-register": "^6.26.0",
    "browser-sync": "^2.26.3",
    "dateformat": "^3.0.3",
    "fancy-log": "^1.3.2",
    "gulp": "^4.0",
    "gulp-autoprefixer": "^6.0.0",
    "gulp-babel": "^8.0.0",
    "gulp-clean-css": "^4.0.0",
    "gulp-cli": "^2.0.1",
    "gulp-concat": "^2.6.1",
    "gulp-extname": "^0.2.2",
    "gulp-if": "^2.0.2",
    "gulp-imagemin": "^5.0.3",
    "gulp-load-plugins": "^1.5.0",
    "gulp-phpcbf": "^0.1.2",
    "gulp-phpcs": "^2.2.0",
    "gulp-rev": "^9.0.0",
    "gulp-sass": "^4.0.2",
    "gulp-sourcemaps": "^2.6.4",
    "gulp-uglify": "^3.0.1",
    "gulp-zip": "^4.2.0",
    "js-yaml": "^3.12.0",
    "rimraf": "^2.6.2",
    "style-sherpa": "^1.0.2",
    "vinyl-named": "^1.1.0",
    "webpack": "^4.26.1",
    "webpack-stream": "^5.1.1",
    "yargs": "^12.0.5"
  },
  "repository": {
    "type": "git",
    "url": "https://github.com/olefredrik/foundationpress.git"
  },
  "bugs": {
    "url": "https://github.com/olefredrik/foundationpress/issues"
  },
  "babel": {
    "presets": [
      "es2015"
    ]
  }
}

webpack 4 uses modes so adding this to gulpfile:

const webpack = {
  config: {
    mode: PRODUCTION ? 'production': 'development',
 // old setup

It is missing the latest @babel/core update. I also removed some packages not used (panini?) and i think other can be scraped. Useful?

PS: version 4(webpack).65(foundation)

JPOak commented 5 years ago

@mattbag I did a quick test of this on all the commands (minus the package command) and it worked well, except for as you mentioned @babel needing to be updated. Probably need to make sure that you PR a new package-lock file as well. I think that was forgotten on the last PR with the Gulp update.

That's my two cents : ). Maybe others will chime in as well.