chore: update ts parser for description comment fixes and generic types (#28709)
* chore: update ts parser for description comment fixes * docs: strongly type the getUserDefault API * spec: add getUserMedia type assertions to smoke run
This commit is contained in:
parent
ac9ec1a6ea
commit
400d7c4bce
6 changed files with 56 additions and 19 deletions
|
@ -159,13 +159,13 @@ Same as `unsubscribeNotification`, but removes the subscriber from `NSWorkspace.
|
|||
|
||||
Add the specified defaults to your application's `NSUserDefaults`.
|
||||
|
||||
### `systemPreferences.getUserDefault(key, type)` _macOS_
|
||||
### `systemPreferences.getUserDefault<Type extends keyof UserDefaultTypes>(key, type)` _macOS_
|
||||
|
||||
* `key` String
|
||||
* `type` String - Can be `string`, `boolean`, `integer`, `float`, `double`,
|
||||
* `type` Type - Can be `string`, `boolean`, `integer`, `float`, `double`,
|
||||
`url`, `array` or `dictionary`.
|
||||
|
||||
Returns `any` - The value of `key` in `NSUserDefaults`.
|
||||
Returns [`UserDefaultTypes[Type]`](structures/user-default-types.md) - The value of `key` in `NSUserDefaults`.
|
||||
|
||||
Some popular `key` and `type`s are:
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue