ember-cli-typescript icon indicating copy to clipboard operation
ember-cli-typescript copied to clipboard

Type for location missing in Routing types

Open Alonski opened this issue 3 years ago • 1 comments

Which package(s) does this problem pertain to?

  • [ ] @types/ember
  • [ ] @types/ember__string
  • [ ] @types/ember__polyfills
  • [ ] @types/ember__object
  • [ ] @types/ember__utils
  • [ ] @types/ember__array
  • [ ] @types/ember__engine
  • [ ] @types/ember__debug
  • [ ] @types/ember__runloop
  • [ ] @types/ember__error
  • [ ] @types/ember__controller
  • [ ] @types/ember__component
  • [X] @types/ember__routing
  • [ ] @types/ember__application
  • [ ] @types/ember__test
  • [ ] @types/ember__test-helpers
  • [ ] @types/ember__service
  • [ ] @types/ember-data
  • [ ] @types/rsvp
  • [ ] Other
  • [ ] I don't know

What are instructions we can follow to reproduce the issue?

Look at the types for the Router Service:
https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/ember__routing/router-service.d.ts
Reproduction Case

**Link: ** https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/ember__routing/router-service.d.ts Location is missing from types: https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/ember__routing/router-service.d.ts

Now about that bug. What did you expect to see?

I expect location to be typed on the RouterService declarations as declared here: https://github.com/emberjs/ember.js/blob/v3.16.10/packages/%40ember/-internals/routing/lib/services/router.ts#L468

What happened instead?

location doesn't exist on the RouterService declarations

Alonski avatar Jun 28 '22 17:06 Alonski

@Alonski thanks for the report, and sorry for the delay. Should be a pretty easy thing to add – please open a PR on DT and we'll get it reviewed and merged!

chriskrycho avatar Aug 29 '22 03:08 chriskrycho

Resolved via shipping native types from source in Ember 5.1 🎉

chriskrycho avatar Sep 28 '23 22:09 chriskrycho