2014-11-05 19:25:53 +00:00
# TypeScript Definitions #
2015-05-09 01:55:12 +00:00
Reference the `phaser.d.ts` in your project.
2014-11-05 19:25:53 +00:00
2015-05-09 01:55:12 +00:00
Please use TypeScript 1.4+
2014-11-05 19:25:53 +00:00
2015-05-09 01:55:12 +00:00
- `phaser.d.ts` contains a reference to `pixi.d.ts` and `p2.d.ts` and so both these files must remain siblings in the same directory.
- `pixi.d.ts` has deviated from the official project. If you are a pixi user, pick up the ball over at [the official pixi typescript repo ](https://github.com/pixijs/pixi-typescript ).
2014-11-05 21:52:00 +00:00
2016-06-20 15:43:36 +00:00
## Including typescript definitions in your project using Typings
You can now use typings, the TypeScript Definition Manager, to include Phaser's typescript definitions in your project:
- Make sure that typings is installed in your system: `npm install -g typings`
- Install phaser typescript definitions as a global dependency:
```
typings install github:photonstorm/phaser/typescript/typings.json -GD
```
This will make phaser typescript definitions available for your compiler so that there is no need to reference them from your source files.
For more information, check [the official typings site ](https://github.com/typings/typings ).
2014-11-05 21:52:00 +00:00
## Contributing ##
2015-08-01 11:06:25 +00:00
If you find any mistakes in these definitions or you feel they can be improved in any way, please make a pull request against the dev branch.
## Note ##
2016-06-17 10:52:46 +00:00
`Creature` defs are not yet provided.
The Box2D defs come from https://github.com/SBCGames/Phaser-Box2D-Typescript-defs