Closed NeoLegends closed 6 years ago
Merging #281 into master will not change coverage. The diff coverage is
n/a
.
@@ Coverage Diff @@
## master #281 +/- ##
=======================================
Coverage 98.61% 98.61%
=======================================
Files 28 28
Lines 362 362
=======================================
Hits 357 357
Misses 5 5
Continue to review full report at Codecov.
Legend - Click here to learn more
Ξ = absolute <relative> (impact)
,ΓΈ = not affected
,? = missing data
Powered by Codecov. Last update 15886ad...a7483b5. Read the comment docs.
Good catch @NeoLegends! I'd still like to make some sort of contract saying that these need to be objects. Perhaps we could use index
signatures, similar to how we do with the Routes
interface? Let me know your thoughts on this. Something like:
interface ObjLiteral {
[key: string]: any;
}
I've never been truly certain on how to deal with objects of unknown shape in TS. any
is a great escape hatch if we need it, but would like to use something a bit safer if possible. Thanks!
This would prevent setting these to null
y values, sounds good! I'll update the PR.
@NeoLegends this looks good to me, finally had some time to review and all seems to be going smoothly. Please pull latest from master
into your branch and then push to this PR and I can merge. cc @ryan-roemer @tptee We can cut a patch release later this week to pull in these updated defs along with #280.
π’
π€π»
@parkerziegler @ryan-roemer @tptee Any chance of getting this released, please?
Thanks for pinging us @davidgruar! Meant to cut another release after these got merged but forgot.
@ryan-roemer @tptee I'm happy to cut a new release later today, how do we want to do versioning (major/minor/patch)? IIRC, the diff is just changes to TS defs β I'll need to verify that.
@davidgruar v15.1.1 is published to npm
. Let us know if you encounter anything funny!
Thank you! It would be worth mentioning #280 in the release notes - it resolves the same issue as #282 but for Typescript (and is actually what I most needed this release for).
Good call out, it's been added!
Hey! I've got another bug in the TS typings that's waiting to be fixed. :)
{}
does not represent a 'plain object' in TS. This leads to problems usingstate.router.result.someProperty
, because TS asserts thatsomeProperty
doesn't exist, when in fact, it does.any
is the right type to be used here.