Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migration to typings #27

Closed
kitsonk opened this issue Mar 29, 2016 · 9 comments
Closed

Migration to typings #27

kitsonk opened this issue Mar 29, 2016 · 9 comments
Assignees
Milestone

Comments

@kitsonk
Copy link
Member

kitsonk commented Mar 29, 2016

We should consider migrating to typings/typings for type management for Dojo 2. It solves some of the challenges that TSD and the other sort of issues that can occur with complex type management and dependencies.

@kitsonk kitsonk added this to the beta.1 milestone Mar 29, 2016
@kitsonk kitsonk modified the milestones: 2016.05, beta.1 Apr 8, 2016
@kitsonk
Copy link
Member Author

kitsonk commented Apr 8, 2016

Actually, we need to do it, since DTS and DefinitelyTyped have been officially deprecated by the TypeScript team in lieu of typings/typings.

@tomdye
Copy link
Member

tomdye commented May 17, 2016

Worth noting this may be required as part of the transition for dojo-core: dojo/core#162

kitsonk added a commit to dojo/compose that referenced this issue May 17, 2016
* Integrate grunt-dojo2
* Realign distribution build (refs: dojo/meta#18)
* Migrates to typings/typings, except for /tests (refs: dojo/meta#27)
* Add prepublish and test to package.json
kitsonk added a commit to dojo/loader that referenced this issue May 18, 2016
* Integrate grunt-dojo2
* Realign distribution build (refs: dojo/meta#18)
* Migrates to typings/typings, except for /tests (refs: dojo/meta#27)
* Add prepublish and test to package.json
@vansimke
Copy link

@kitsonk Could you take a look at https://github.com/vansimke/core/tree/meta_issue_27 and let me know what you think? Everything seems to work except from grunt dist_esm which is running into some weird errors during compilation that I didn't have time to dig into today.

@kitsonk
Copy link
Member Author

kitsonk commented May 19, 2016

@vansimke, thank you! It is fine to leave it without grunt dist_esm for now and we can enhance that over a period of time. Most of it will because you are loading some typings at compile time that are duplicates of what is defined elsewhere. There is no easy way to deal with different sets of typings with different targets at the moment yet that I am aware of.

Couple notes though:

  • I would prefer we find more respectable places to pull the typings from the previous history of the repo. For all the ones that aren't well published at the moment (or we have to use a custom version like node), we should add them to dojo/typings/custom and reference them there.
  • Also, we will need to supply the symbol-shim as it will be needed by downstream packages that are targeted at ES5.
  • While you excluded the /typings from .gitignore you still have some files checked into those paths. That will leave them "abandoned" and never updated. You should git -rm /typings/ and git -rm /tests/typings/
  • I would also do an npm pack on the package which will produce a .tgz which would represent what we publish on npm. I would extract that then and validate that it has the files in way you expect and nothing you don't expect or like.

@kitsonk
Copy link
Member Author

kitsonk commented May 19, 2016

A consolidated diff if anyone else wants to have a look.

kitsonk added a commit to dojo/widget-core that referenced this issue May 19, 2016
* Integrate grunt-dojo2
* Realign distribution build (refs: dojo/meta#18)
* Migrates to typings/typings, except for /tests (refs: dojo/meta#27)
* Add prepublish and test to package.json
@vansimke
Copy link

Yeah, I was only trying to get a straw man out there. I'll clean things up and then submit a PR for it.

@vansimke
Copy link

I've made some updates to my fork, but I'm not happy about where things are at. Currently, due to the conflicts between the different typings (which is exacerbated by including symbol-shim), npm install fails due to conflicts in grunt dist. I think that it is related to this issue, and I couldn't figure out how to get around it. Somehow dojo/core:master works, but as soon as I change from tsd to typings/typings, it starts to complain.

If we're okay with this direction, then I can submit a PR to dojo/typings to add the new typings that I need to centralize the non-published type definitions and then update this branch to point to those definitions.

@kitsonk
Copy link
Member Author

kitsonk commented May 23, 2016

@vansimke sorry to send you on a fools errand. I am in the process of adapting dojo-core, because we need to get a new release out for some downstream development. I apologise too much of this is in my head at the moment to be able to effectively get someone else to be able to address it, but I suspect it will just be easier for everyone if I just finish it off.

kitsonk added a commit to dojo/core that referenced this issue May 23, 2016
* Integrate grunt-dojo2
* Realign distribution build (refs: dojo/meta#18)
* Migrates to typings/typings, except for /tests (refs: dojo/meta#27)
* Add prepublish and test to package.json
kitsonk added a commit to dojo/actions that referenced this issue May 25, 2016
* Integrate grunt-dojo2
* Realign distribution build (refs: dojo/meta#18)
* Migrates to typings/typings (refs: dojo/meta#27)
* Add prepublish and test to package.json
* Other packaging updates
kitsonk added a commit to dojo/dom that referenced this issue Jun 1, 2016
* Integrate grunt-dojo2
* Realign distribution build (refs: dojo/meta#18)
* Migrates to typings/typings, except for /tests (refs: dojo/meta#27)
* Add prepublish and test to package.json
@kitsonk kitsonk self-assigned this Jun 7, 2016
@kitsonk kitsonk modified the milestones: 2016.06, 2016.05 Jun 7, 2016
@kitsonk kitsonk modified the milestones: 2016.06, 2016.07 Jul 4, 2016
@kitsonk kitsonk modified the milestones: 2016.07, 2016.08 Aug 1, 2016
@kitsonk
Copy link
Member Author

kitsonk commented Sep 7, 2016

Actually we have completed this work, though we now need to migrate to @types (just in time)

@kitsonk kitsonk closed this as completed Sep 7, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants