Typescript 2.2 update #746

Closed
opened 2017-07-22 20:28:45 +00:00 by rcfrias · 2 comments
rcfrias commented 2017-07-22 20:28:45 +00:00 (Migrated from github.com)

For Typescript 2.2, in the index.d.ts <- file, the "object" type needs to be changed to "Object". And the file needs to be moved from the type folder to the root folder in order to be recognized by the typescript compiler.

For Typescript 2.2, in the index.d.ts <- file, the "object" type needs to be changed to "Object". And the file needs to be moved from the type folder to the root folder in order to be recognized by the typescript compiler.
SheetJSDev commented 2017-07-22 20:40:43 +00:00 (Migrated from github.com)

Does Object work in newer versions of TS too?

The structure was based on the official documentation and the dtslint README. If that is not working in TS 2.2, it's probably worth raising an issue there to get a clarification.

Does `Object` work in newer versions of TS too? The structure was based on the [official documentation](http://www.typescriptlang.org/docs/handbook/declaration-files/publishing.html) and the [dtslint README](https://github.com/Microsoft/dtslint). If that is not working in TS 2.2, it's probably worth raising an issue there to get a clarification.
rcfrias commented 2017-07-23 23:05:30 +00:00 (Migrated from github.com)

Yes, I can confirm this. I got it to work for me, this is a good post that explains the update. I only had to change one line in the index.d.ts(line 523):

/** The style/theme of the cell (if applicable) */
    s?: Object;  // <- it was object before.

and this is the explanation for the second argument.
I would have submitted a pull request, but the code is nowhere to find to do this.

Yes, I can confirm this. I got it to work for me, [this is a good post](https://blog.mariusschulz.com/2017/02/24/typescript-2-2-the-object-type) that explains the update. I only had to change one line in the index.d.ts(line 523): ``` /** The style/theme of the cell (if applicable) */ s?: Object; // <- it was object before. ``` [and this](https://www.typescriptlang.org/docs/handbook/declaration-files/templates/module-d-ts.html) is the explanation for the second argument. I would have submitted a pull request, but the code is nowhere to find to do this.
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: sheetjs/sheetjs#746
No description provided.