Skip to content
This repository has been archived by the owner on Oct 10, 2022. It is now read-only.

[Idea][cgb-scripts] Move ownPackage to devDependencies on eject command #72

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

ryo-utsunomiya
Copy link

@ryo-utsunomiya ryo-utsunomiya commented Jun 23, 2018

Currently, eject command outputs cgb dependencies to the app dependencies. In my opinion, create-guten-block's dependencies are devDependencies of the app. This PR includes my idea of improving eject.

After modification, package.json(after eject) looks like this:

{
  "name": "eject-test-cgb-guten-block",
  "version": "1.0.0",
  "private": true,
  "scripts": {
    "start": "node scripts/start.js",
    "build": "node scripts/build.js"
  },
  "dependencies": {},
  "devDependencies": {
    "autoprefixer": "^7.2.4",
    "babel-core": "^6.25.0",
    "babel-eslint": "^8.2.1",
    "babel-loader": "^7.1.1",
    "babel-preset-cgb": "^1.4.0",
    "cgb-dev-utils": "^1.4.0",
    "chalk": "^2.3.0",
    "cross-env": "^5.0.1",
    "cross-spawn": "^5.1.0",
    "eslint": "^4.15.0",
    "eslint-config-wordpress": "^2.0.0",
    "eslint-plugin-jest": "^21.6.1",
    "eslint-plugin-jsx-a11y": "^6.0.3",
    "eslint-plugin-react": "^7.5.1",
    "eslint-plugin-wordpress": "^0.1.0",
    "extract-text-webpack-plugin": "^3.0.2",
    "filesize": "^3.5.11",
    "fs-extra": "^5.0.0",
    "gzip-size": "^4.1.0",
    "inquirer": "^5.0.0",
    "node-sass": "^4.7.2",
    "ora": "^1.3.0",
    "postcss-loader": "^2.0.10",
    "raw-loader": "^0.5.1",
    "resolve-pkg": "^1.0.0",
    "sass-loader": "^6.0.6",
    "shelljs": "^0.8.0",
    "style-loader": "^0.19.1",
    "update-notifier": "^2.3.0",
    "webpack": "^3.1.0"
  },
  "babel": {
    "presets": [
      [
        "env",
        {
          "modules": false,
          "targets": {
            "browsers": [
              "last 2 Chrome versions",
              "last 2 Firefox versions",
              "last 2 Safari versions",
              "last 2 iOS versions",
              "last 1 Android version",
              "last 1 ChromeAndroid version",
              "ie 11"
            ]
          }
        }
      ]
    ],
    "plugins": [
      [
        "transform-object-rest-spread"
      ],
      [
        "transform-object-rest-spread",
        {
          "useBuiltIns": true
        }
      ],
      [
        "transform-react-jsx",
        {
          "pragma": "wp.element.createElement"
        }
      ],
      [
        "transform-runtime",
        {
          "helpers": false,
          "polyfill": false,
          "regenerator": true
        }
      ]
    ]
  }
}

Screenshot:
screen shot 2018-06-23 at 15 46 35

@ryo-utsunomiya ryo-utsunomiya changed the title [Idea] Move ownPackage to devDependencies [Idea] Move ownPackage to devDependencies on eject command Jun 23, 2018
@ryo-utsunomiya ryo-utsunomiya changed the title [Idea] Move ownPackage to devDependencies on eject command [Idea][cgb-scripts] Move ownPackage to devDependencies on eject command Jun 23, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants