Skip to content

Latest commit

 

History

History
29 lines (21 loc) · 1.16 KB

Ionic.md

File metadata and controls

29 lines (21 loc) · 1.16 KB

Ionic

For using Phaser CE with ionic, have a look at the ionic example within project templates. To get phaser-ce working with ionic in general, you've to extend "only" the webpack config used by ionic. To get this done are a few steps are necessary.

  1. Install dependencies webpack-merge and expose-loader:

    npm install webpack-merge expose-loader --save-dev
  2. Create a new webpack config setting up expose-loader and merging it with the ionic webpack script.

  3. Add own webpack config at package.json, so that ionic will use it:

    {
      "config": {
        "ionic_webpack": "./webpack.config.js"
      }
    }
  4. Import pixi, p2 and phaser-ce within your project:

    import "pixi";
    import "p2";
    import * as Phaser from "phaser-ce";