Skip to content
This repository has been archived by the owner on Feb 23, 2023. It is now read-only.

Fix definition file for TypeScript 1.6 #16

Merged
merged 1 commit into from
Aug 20, 2015

Conversation

DanielRosenwasser
Copy link
Contributor

TypeScript 1.6 will be making a breaking change where object literals with excess properties will cause an error. As part of a sweep through DefinitelyTyped (microsoft/TypeScript#4081), I found that pixi's tests were causing errors, though the only errors I see in the tests are

Error TS2345 Argument of type '{ backgroundColor: number; }' is not assignable to parameter of type 'RendererOptions'.
  Object literal may only specify known properties, and 'backgroundColor' does not exist in type 'RendererOptions'.

I added a backgroundColor property to RendererOptions to fix this, but if there are any others that are missing, we should add them to avoid breaks in consumer code.

clark-stevenson added a commit that referenced this pull request Aug 20, 2015
Fix definition file for TypeScript 1.6
@clark-stevenson clark-stevenson merged commit fe05499 into pixijs:master Aug 20, 2015
@clark-stevenson
Copy link
Collaborator

Awesome @DanielRosenwasser I do not know where you find the time!

I have added a review to my todo this weekend to check for any other rogues.

Thanks

@DanielRosenwasser
Copy link
Contributor Author

You're welcome! Do you generally sync up the changes to DefinitelyTyped, or would it be easier if I took care of it?

@DanielRosenwasser DanielRosenwasser deleted the fixForOneSix branch August 21, 2015 00:24
@clark-stevenson
Copy link
Collaborator

@bfanger only recently made a PR to push to DT at #14

I am really far behind with all the Definitely Typed stuff so he may be able to answer more credibly than me.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants