babel6.5にバージョンをあげたらwebpackのビルドで `Missing class properties transform`

babelのバージョンをおもむろに6.5近辺の最新にあげたところ、
webpackのビルドが`Missing class properties transform`というエラーで死ぬようになりました。

回避策を備忘録的に残しておきます。
（まぁそのうち必要なくなるでしょうが...)

## 関連モジュールのバージョン

| モジュール | バージョン |
|------------|------------|
| babel | 6.5.2 |
| babel-cli | 6.6.5 |
| babel-core | 6.7.0 |
| babel-eslint | 5.0.0 |
| babel-loader | 6.2.4 |
| babel-preset-es2015 | 6.6.0 |
| webpack | 1.2.14 |
| babel-plugin-transform-class-properties | 6.6.0 |


## エラーの内容

```
Module build failed: SyntaxError: /XXXX/index.jsx: Missing class properties transform.
  10 | export default class Hoge extends React.Component {
> 20 |   static propTypes = {
     |   ^
    at File.buildCodeFrameError (/XXX//node_modules/babel-core/lib/transformation/file/index.js:407:15)
    at NodePath.buildCodeFrameError (/XXX//node_modules/babel-traverse/lib/path/index.js:149:26)
    at [object Object].pushBody (/XXX//node_modules/babel-plugin-transform-es2015-classes/lib/vanilla.js:254:20)
    at [object Object].buildBody (/XXX//node_modules/babel-plugin-transform-es2015-classes/lib/vanilla.js:233:10)
    at [object Object].run (/XXX//node_modules/babel-plugin-transform-es2015-classes/lib/vanilla.js:151:10)
    at PluginPass.ClassExpression (/XXX//node_modules/babel-plugin-transform-es2015-classes/lib/index.js:63:60)
    at newFn (/XXX//node_modules/babel-traverse/lib/visitors.js:262:19)
    at NodePath._call (/XXX//node_modules/babel-traverse/lib/path/context.js:63:18)
    at NodePath.call (/XXX//node_modules/babel-traverse/lib/path/context.js:47:17)
    at NodePath.visit (/XXX//node_modules/babel-traverse/lib/path/context.js:93:12)
    at TraversalContext.visitQueue (/XXX//node_modules/babel-traverse/lib/context.js:146:16)
    at TraversalContext.visitSingle (/XXX//node_modules/babel-traverse/lib/context.js:115:19)
    at TraversalContext.visit (/XXX//node_modules/babel-traverse/lib/context.js:178:19)
    at Function.traverse.node (/XXX//node_modules/babel-traverse/lib/index.js:135:17)
    at NodePath.visit (/XXX//node_modules/babel-traverse/lib/path/context.js:103:22)
    at TraversalContext.visitQueue (/XXX//node_modules/babel-traverse/lib/context.js:146:16)
    at TraversalContext.visitMultiple (/XXX//node_modules/babel-traverse/lib/context.js:110:17)
    at TraversalContext.visit (/XXX//node_modules/babel-traverse/lib/context.js:176:19)
    at Function.traverse.node (/XXX//node_modules/babel-traverse/lib/index.js:135:17)
    at NodePath.visit (/XXX//node_modules/babel-traverse/lib/path/context.js:103:22)
    at TraversalContext.visitQueue (/XXX//node_modules/babel-traverse/lib/context.js:146:16)
    at TraversalContext.visitQueue (/XXX//node_modules/babel-traverse/lib/context.js:152:21)
    at TraversalContext.visitQueue (/XXX//node_modules/babel-traverse/lib/context.js:152:21)
    at TraversalContext.visitMultiple (/XXX//node_modules/babel-traverse/lib/context.js:110:17)
    at TraversalContext.visit (/XXX//node_modules/babel-traverse/lib/context.js:176:19)
    at Function.traverse.node (/XXX//node_modules/babel-traverse/lib/index.js:135:17)
    at NodePath.visit (/XXX//node_modules/babel-traverse/lib/path/context.js:103:22)
    at TraversalContext.visitQueue (/XXX//node_modules/babel-traverse/lib/context.js:146:16)
    at TraversalContext.visitSingle (/XXX//node_modules/babel-traverse/lib/context.js:115:19)
    at TraversalContext.visit (/XXX//node_modules/babel-traverse/lib/context.js:178:19)
    at Function.traverse.node (/XXX//node_modules/babel-traverse/lib/index.js:135:17)
    at Object.traverse [as default] (/XXX//node_modules/babel-traverse/lib/index.js:69:12)
```

## 回避策

プラグイン関係の衝突が原因っぽかったので、
passPerPresetを使ってこんな感じで解決しました。

passPerPresetって何って言う話は、[ReleaseNote](https://github.com/babel/babel/releases/tag/v6.5.0)とか[このへん](http://jser.info/2016/02/08/babel6.5.0-angular1.5-let-const/)を読めば分かるかと。

```js
//.babercなりpackage.jsonの"babel"ブロックなりに以下を記述
{
  "passPerPreset": true,
  "presets": [
    // class propertiesの変換だけ先にする
    {
      "plugins": [
        "transform-class-properties"
      ]
    },
    // es2015と同等のライブラリ定義
    // 個別に指定しなくても"es2015"で大丈夫な気がします。
    {
      "plugins": [
        "check-es2015-constants",
        "transform-es2015-arrow-functions",
        "transform-es2015-block-scoped-functions",
        "transform-es2015-block-scoping",
        "transform-es2015-classes",
        "transform-es2015-computed-properties",
        "transform-es2015-destructuring",
        "transform-es2015-duplicate-keys",
        "transform-es2015-for-of",
        "transform-es2015-function-name",
        "transform-es2015-literals",
        "transform-es2015-modules-commonjs",
        "transform-es2015-object-super",
        "transform-es2015-parameters",
        "transform-es2015-shorthand-properties",
        "transform-es2015-spread",
        "transform-es2015-sticky-regex",
        "transform-es2015-template-literals",
        "transform-es2015-typeof-symbol",
        "transform-es2015-unicode-regex",
        "transform-regenerator",
        "transform-react-jsx",
        "transform-decorators-legacy",
        "babel-plugin-espower"
      ]
    }
  ]
}
```

以上です。