- fetchCurrentPatient
- getCurrentUser
- getLocations
- getLoggedInUser
- getSessionLocation
- getVisitTypes
- getVisitsForPatient
- makeUrl
- openmrsFetch
- openmrsObservableFetch
- refetchCurrentUser
- saveVisit
- setSessionLocation
- toLocationObject
- toVisitTypeObject
- updateVisit
- useCurrentPatient
- useLocations
- usePatient
- useSession
- useSessionUser
- useVisit
- useVisitTypes
- userHasAccess
- formatDate
- formatDatetime
- formatTime
- isOmrsDateStrict
- isOmrsDateToday
- parseDate
- toDateObjectStrict
- toOmrsDateFormat
- toOmrsDayDateFormat
- toOmrsIsoString
- toOmrsTimeString
- toOmrsTimeString24
- toOmrsYearlessDateFormat
- attach
- detach
- detachAll
- getAssignedExtensions
- getConnectedExtensions
- getExtensionNameFromId
- getExtensionStore
- renderExtension
- useAssignedExtensionIds
- useAssignedExtensions
- useConnectedExtensions
- useExtensionSlotMeta
- useExtensionStore
- beginEditSynchronizationItem
- canBeginEditSynchronizationItemsOfType
- deleteSynchronizationItem
- generateOfflineUuid
- getCurrentOfflineMode
- getOfflinePatientDataStore
- getSynchronizationItem
- getSynchronizationItems
- isOfflineUuid
- loadPersistedPatientDataSyncState
- messageOmrsServiceWorker
- queueSynchronizationItem
- registerOfflinePatientHandler
- setupOfflineSync
- subscribeConnectivity
- subscribeConnectivityChanged
- subscribePrecacheStaticDependencies
- syncOfflinePatientData
- useConnectivity
- createGlobalStore
- createUseStore
- getAppState
- getGlobalStore
- subscribeTo
- useStore
- useStoreWithActions
- showModal
- showNotification
- showToast
- subscribeNotificationShown
- subscribeToastShown
- useBodyScrollLock
- useLayoutType
- useOnClickOutside
- usePagination
Ƭ CurrentPatient: fhir.Patient
| FetchResponse
<fhir.Patient
>
packages/framework/esm-api/src/shared-api-objects/current-patient.ts:5
Ƭ NullablePatient: fhir.Patient
| null
packages/framework/esm-react-utils/src/usePatient.ts:5
Ƭ PatientUuid: string
| null
packages/framework/esm-api/src/shared-api-objects/current-patient.ts:19
Ƭ DateInput: string
| number
| Date
packages/framework/esm-utils/src/omrs-dates.ts:19
Ƭ FormatDateMode: "standard"
| "wide"
packages/framework/esm-utils/src/omrs-dates.ts:140
Ƭ FormatDateOptions: Object
Name | Type | Description |
---|---|---|
day |
boolean |
Whether to include the day number |
mode |
FormatDateMode |
- standard : "03 Feb 2022" - wide : "03 — Feb — 2022" |
time |
boolean | "for today" |
Whether the time should be included in the output always (true ), never (false ), or only when the input date is today (for today ). |
year |
boolean |
Whether to include the year |
packages/framework/esm-utils/src/omrs-dates.ts:142
Ƭ KnownOmrsServiceWorkerMessages: OnImportMapChangedMessage
| ClearDynamicRoutesMessage
| RegisterDynamicRouteMessage
packages/framework/esm-offline/src/service-worker-messaging.ts:46
Ƭ OfflineMode: "on"
| "off"
| "unavailable"
packages/framework/esm-offline/src/mode.ts:38
Ƭ OmrsOfflineCachingStrategy: "network-only-or-cache-only"
| "network-first"
cache-or-network
: The default strategy, equal to the absence of this header. The SW attempts to resolve the request via the network, but falls back to the cache if required. The service worker decides the strategy to be used.network-first
: See https://developers.google.com/web/tools/workbox/modules/workbox-strategies#network_first_network_falling_back_to_cache.
packages/framework/esm-offline/src/service-worker-http-headers.ts:18
Ƭ OmrsOfflineHttpHeaderNames: keyof OmrsOfflineHttpHeaders
packages/framework/esm-offline/src/service-worker-http-headers.ts:45
Ƭ OmrsOfflineHttpHeaders: Object
Defines the keys of the custom headers which can be appended to an HTTP request. HTTP requests with these headers are handled in a special way by the SPA's service worker.
Name | Type | Description |
---|---|---|
x-omrs-offline-caching-strategy? |
OmrsOfflineCachingStrategy |
Instructs the service worker to use a specific caching strategy for this request. |
x-omrs-offline-response-body? |
string |
If the client is offline and the request cannot be read from the cache (i.e. if there is no way to receive any kind of data for this request), the service worker will return a response with the body in this header. |
x-omrs-offline-response-status? |
`${number}` | If the client is offline and the request cannot be read from the cache (i.e. if there is no way to receive any kind of data for this request), the service worker will return a response with the status code defined in this header. |
packages/framework/esm-offline/src/service-worker-http-headers.ts:26
Ƭ ConfigValue: string
| number
| boolean
| void
| any
[] | object
packages/framework/esm-config/src/types.ts:32
Ƭ ExtensionSlotProps: ExtensionSlotBaseProps
& React.HTMLAttributes
<HTMLDivElement
>
packages/framework/esm-react-utils/src/ExtensionSlot.tsx:48
Ƭ ProvidedConfig: Object
Name | Type |
---|---|
config |
Config |
source |
string |
packages/framework/esm-config/src/types.ts:60
Ƭ SpaEnvironment: "production"
| "development"
| "test"
packages/framework/esm-globals/src/types.ts:55
Ƭ UpdateVisitPayload: NewVisitPayload
& {}
packages/framework/esm-api/src/types/visit-resource.ts:12
Ƭ Validator: (value
: any
) => void
| string
▸ (value
): void
| string
Name | Type |
---|---|
value |
any |
void
| string
packages/framework/esm-config/src/types.ts:67
Ƭ ValidatorFunction: (value
: any
) => boolean
▸ (value
): boolean
Name | Type |
---|---|
value |
any |
boolean
packages/framework/esm-config/src/types.ts:65
Ƭ Actions: Function
| { [key: string]
: Function
; }
packages/framework/esm-react-utils/src/createUseStore.ts:5
Ƭ BoundActions: Object
▪ [key: string
]: BoundAction
packages/framework/esm-react-utils/src/createUseStore.ts:6
Ƭ InlineNotificationType: "error"
| "info"
| "info-square"
| "success"
| "warning"
| "warning-alt"
packages/framework/esm-styleguide/src/notifications/notification.component.tsx:22
Ƭ LayoutType: "tablet"
| "phone"
| "desktop"
packages/framework/esm-react-utils/src/useLayoutType.ts:4
Ƭ ToastType: "error"
| "info"
| "info-square"
| "success"
| "warning"
| "warning-alt"
packages/framework/esm-styleguide/src/toasts/toast.component.tsx:26
• UserHasAccess: React.FC
<UserHasAccessProps
>
packages/framework/esm-react-utils/src/UserHasAccess.tsx:9
• defaultVisitCustomRepresentation: string
packages/framework/esm-api/src/shared-api-objects/visit-utils.ts:12
• fhir: FhirClient
The fhir
object is an instance of fhir.js
that can be used to call FHIR-compliant OpenMRS APIs. See
the docs for fhir.js for more info
and example usage.
packages/framework/esm-api/src/fhir.ts:42
• fhirBaseUrl: "/ws/fhir2/R4"
packages/framework/esm-api/src/fhir.ts:5
• getStartedVisit: BehaviorSubject
<null
| VisitItem
>
packages/framework/esm-api/src/shared-api-objects/visit-utils.ts:74
• sessionEndpoint: "/ws/rest/v1/session"
packages/framework/esm-api/src/openmrs-fetch.ts:7
• validators: Object
Name | Type |
---|---|
inRange |
(min : number , max : number ) => Validator |
isUrl |
Validator |
isUrlWithTemplateParameters |
(allowedTemplateParameters : string []) => Validator |
packages/framework/esm-config/src/validators/validators.ts:58
• ConfigurableLink: React.FC
<ConfigurableLinkProps
>
A React link component which calls navigate when clicked
param
The target path or URL. Supports interpolation. See navigate
param
Inline elements within the link
param
Any other valid props for an tag except href
and onClick
packages/framework/esm-react-utils/src/ConfigurableLink.tsx:32
• offlineUuidPrefix: "OFFLINE+"
packages/framework/esm-offline/src/uuid.ts:4
• omrsOfflineCachingStrategyHttpHeaderName: "x-omrs-offline-caching-strategy"
packages/framework/esm-offline/src/service-worker-http-headers.ts:7
• omrsOfflineResponseBodyHttpHeaderName: "x-omrs-offline-response-body"
packages/framework/esm-offline/src/service-worker-http-headers.ts:3
• omrsOfflineResponseStatusHttpHeaderName: "x-omrs-offline-response-status"
packages/framework/esm-offline/src/service-worker-http-headers.ts:5
• Extension: React.FC
<ExtensionProps
>
Represents the position in the DOM where each extension within an extension slot is rendered.
Renders once for each extension attached to that extension slot.
Usage of this component must have an ancestor <ExtensionSlot>
,
and must only be used once within that <ExtensionSlot>
.
packages/framework/esm-react-utils/src/Extension.tsx:23
• ExtensionSlot: React.FC
<ExtensionSlotProps
>
packages/framework/esm-react-utils/src/ExtensionSlot.tsx:55
• backendDependencies: Object
Name | Type |
---|---|
fhir2 |
string |
webservices.rest |
string |
packages/framework/esm-api/src/openmrs-backend-dependencies.ts:1
▸ fetchCurrentPatient(patientUuid
, contentOverrides?
): Promise
<{ data
: Patient
}> | Promise
<null
>
Name | Type |
---|---|
patientUuid |
PatientUuid |
contentOverrides? |
Partial <{ headers? : FetchHeaders ; id? : string ; patient? : string ; type : ResourceName }> |
Promise
<{ data
: Patient
}> | Promise
<null
>
packages/framework/esm-api/src/shared-api-objects/current-patient.ts:21
▸ getCurrentUser(): Observable
<LoggedInUser
>
The getCurrentUser function returns an observable that produces zero or more values, over time. It will produce zero values by default if the user is not logged in. And it will provide a first value when the logged in user is fetched from the server. Subsequent values will be produced whenever the user object is updated.
Observable
<LoggedInUser
>
An Observable that produces zero or more values (as
described above). The values produced will be a user object (if
includeAuthStatus
is set to false
) or an object with a session
and authenticated property (if includeAuthStatus
is set to true
).
import { getCurrentUser } from '@openmrs/esm-api'
const subscription = getCurrentUser().subscribe(
user => console.log(user)
)
subscription.unsubscribe()
getCurrentUser({includeAuthStatus: true}).subscribe(
data => console.log(data.authenticated)
)
Otherwise your code will continue getting updates to the user object even after the UI component is gone from the screen. This is a memory leak and source of bugs.
packages/framework/esm-api/src/shared-api-objects/current-user.ts:57
▸ getCurrentUser(opts
): Observable
<Session
>
Name | Type |
---|---|
opts |
CurrentUserWithResponseOption |
Observable
<Session
>
packages/framework/esm-api/src/shared-api-objects/current-user.ts:58
▸ getCurrentUser(opts
): Observable
<LoggedInUser
>
Name | Type |
---|---|
opts |
CurrentUserWithoutResponseOption |
Observable
<LoggedInUser
>
packages/framework/esm-api/src/shared-api-objects/current-user.ts:61
▸ getLocations(): Observable
<Location
[]>
Observable
<Location
[]>
packages/framework/esm-api/src/shared-api-objects/location.ts:14
▸ getLoggedInUser(): Promise
<LoggedInUser
>
Promise
<LoggedInUser
>
packages/framework/esm-api/src/shared-api-objects/current-user.ts:136
▸ getSessionLocation(): Promise
<undefined
| SessionLocation
>
Promise
<undefined
| SessionLocation
>
packages/framework/esm-api/src/shared-api-objects/current-user.ts:145
▸ getVisitTypes(): Observable
<VisitType
[]>
Observable
<VisitType
[]>
packages/framework/esm-api/src/shared-api-objects/visit-type.ts:15
▸ getVisitsForPatient(patientUuid
, abortController
, v?
): Observable
<FetchResponse
<{ results
: Visit
[] }>>
Name | Type |
---|---|
patientUuid |
string |
abortController |
AbortController |
v? |
string |
Observable
<FetchResponse
<{ results
: Visit
[] }>>
packages/framework/esm-api/src/shared-api-objects/visit-utils.ts:20
▸ makeUrl(path
): string
Append path
to the OpenMRS SPA base.
makeUrl('/foo/bar');
// => '/openmrs/foo/bar'
Name | Type |
---|---|
path |
string |
string
packages/framework/esm-api/src/openmrs-fetch.ts:19
▸ openmrsFetch<T
>(path
, fetchInit?
): Promise
<FetchResponse
<T
>>
The openmrsFetch function is a wrapper around the browser's built-in fetch function, with extra handling for OpenMRS-specific API behaviors, such as request headers, authentication, authorization, and the API urls.
Name | Type |
---|---|
T |
any |
Name | Type | Description |
---|---|---|
path |
string |
A string url to make the request to. Note that the openmrs base url (by default /openmrs ) will be automatically prepended to the URL, so there is no need to include it. |
fetchInit |
FetchConfig |
A fetch init object. Note that the body property does not need to be JSON.stringify() ed because openmrsFetch will do that for you. |
Promise
<FetchResponse
<T
>>
A Promise
that resolves with a Response object.
Note that the openmrs version of the Response object has already
downloaded the HTTP response body as json, and has an additional
data
property with the HTTP response json as a javascript object.
import { openmrsFetch } from '@openmrs/esm-api'
const abortController = new AbortController();
openmrsFetch('/ws/rest/v1/session', {signal: abortController.signal})
.then(response => {
console.log(response.data.authenticated)
})
.catch(err => {
console.error(err.status);
})
abortController.abort();
openmrsFetch('/ws/rest/v1/session', {
method: 'POST',
body: {
username: 'hi',
password: 'there',
}
})
To cancel a network request, use an AbortController. It is best practice to cancel your network requests when the user navigates away from a page while the request is pending request, to free up memory and network resources and to prevent race conditions.
packages/framework/esm-api/src/openmrs-fetch.ts:72
▸ openmrsObservableFetch<T
>(url
, fetchInit?
): Observable
<FetchResponse
<T
>>
The openmrsObservableFetch function is a wrapper around openmrsFetch that returns an Observable instead of a promise. It exists in case using an Observable is preferred or more convenient than a promise.
Name |
---|
T |
Name | Type | Description |
---|---|---|
url |
string |
See openmrsFetch |
fetchInit |
FetchConfig |
See openmrsFetch |
Observable
<FetchResponse
<T
>>
An Observable that produces exactly one Response object. The response object is exactly the same as for openmrsFetch.
import { openmrsObservableFetch } from '@openmrs/esm-api'
const subscription = openmrsObservableFetch('/ws/rest/v1/session').subscribe(
response => console.log(response.data),
err => {throw err},
() => console.log('finished')
)
subscription.unsubscribe()
To cancel the network request, simply call subscription.unsubscribe();
packages/framework/esm-api/src/openmrs-fetch.ts:243
▸ refetchCurrentUser(): void
The refetchCurrentUser
function causes a network request to redownload
the user. All subscribers to the current user will be notified of the
new users once the new version of the user object is downloaded.
void
The same observable as returned by getCurrentUser.
import { refetchCurrentUser } from '@openmrs/esm-api'
refetchCurrentUser()
packages/framework/esm-api/src/shared-api-objects/current-user.ts:115
▸ saveVisit(payload
, abortController
): Observable
<FetchResponse
<any
>>
Name | Type |
---|---|
payload |
NewVisitPayload |
abortController |
AbortController |
Observable
<FetchResponse
<any
>>
packages/framework/esm-api/src/shared-api-objects/visit-utils.ts:45
▸ setSessionLocation(locationUuid
, abortController
): Promise
<any
>
Name | Type |
---|---|
locationUuid |
string |
abortController |
AbortController |
Promise
<any
>
packages/framework/esm-api/src/shared-api-objects/current-user.ts:157
▸ toLocationObject(openmrsRestForm
): Location
Name | Type |
---|---|
openmrsRestForm |
any |
packages/framework/esm-api/src/shared-api-objects/location.ts:7
▸ toVisitTypeObject(openmrsRestForm
): VisitType
Name | Type |
---|---|
openmrsRestForm |
any |
packages/framework/esm-api/src/shared-api-objects/visit-type.ts:7
▸ updateVisit(uuid
, payload
, abortController
): Observable
<any
>
Name | Type |
---|---|
uuid |
string |
payload |
NewVisitPayload |
abortController |
AbortController |
Observable
<any
>
packages/framework/esm-api/src/shared-api-objects/visit-utils.ts:59
▸ useCurrentPatient(patientUuid?
): [boolean
, NullablePatient
, PatientUuid
, Error
| null
]
This React hook returns the current patient, as specified by the current route. It returns all the information needed to render a loading state, error state, and normal/success state.
deprecated
Use usePatient instead.
Name | Type |
---|---|
patientUuid |
PatientUuid |
[boolean
, NullablePatient
, PatientUuid
, Error
| null
]
packages/framework/esm-react-utils/src/useCurrentPatient.ts:83
▸ useLocations(): Location
[]
Location
[]
packages/framework/esm-react-utils/src/useLocations.tsx:5
▸ usePatient(patientUuid?
): Object
This React hook returns a patient object. If the patientUuid
is provided
as a parameter, then the patient for that UUID is returned. If the parameter
is not provided, the patient UUID is obtained from the current route, and
a route listener is set up to update the patient whenever the route changes.
Name | Type |
---|---|
patientUuid? |
string |
Object
Name | Type |
---|---|
error |
null | Error |
isLoading |
boolean |
patient |
NullablePatient |
patientUuid |
null | string |
packages/framework/esm-react-utils/src/usePatient.ts:92
▸ useSession(): null
| Session
null
| Session
packages/framework/esm-react-utils/src/useSessionUser.tsx:5
▸ Const
useSessionUser(): null
| Session
deprecated
null
| Session
packages/framework/esm-react-utils/src/useSessionUser.tsx:21
▸ useVisit(patientUuid
): VisitReturnType
This React hook returns a visit object. If the patientUuid
is provided
as a parameter, then the currentVisit, error and mutate function
for that patient visit is returned.
Name | Type | Description |
---|---|---|
patientUuid |
string |
Unique patient identifier string |
VisitReturnType
Object {error
isValidating
, currentVisit
, mutate
}
packages/framework/esm-react-utils/src/useVisit.ts:27
▸ useVisitTypes(): VisitType
[]
packages/framework/esm-react-utils/src/useVisitTypes.ts:5
▸ userHasAccess(requiredPrivilege
, user
): undefined
| Privilege
Name | Type |
---|---|
requiredPrivilege |
string |
user |
Object |
user.privileges |
Privilege [] |
user.roles |
Role [] |
undefined
| Privilege
packages/framework/esm-api/src/shared-api-objects/current-user.ts:129
▸ filterBreadcrumbs(list
, path
): BreadcrumbRegistration
[]
Name | Type |
---|---|
list |
BreadcrumbRegistration [] |
path |
string |
packages/framework/esm-breadcrumbs/src/filter.ts:43
▸ getBreadcrumbs(): BreadcrumbRegistration
[]
packages/framework/esm-breadcrumbs/src/db.ts:35
▸ getBreadcrumbsFor(path
): BreadcrumbRegistration
[]
Name | Type |
---|---|
path |
string |
packages/framework/esm-breadcrumbs/src/filter.ts:66
▸ registerBreadcrumb(breadcrumb
): void
Name | Type |
---|---|
breadcrumb |
BreadcrumbSettings |
void
packages/framework/esm-breadcrumbs/src/db.ts:21
▸ registerBreadcrumbs(breadcrumbs
): void
Name | Type |
---|---|
breadcrumbs |
BreadcrumbSettings [] |
void
packages/framework/esm-breadcrumbs/src/db.ts:25
▸ defineConfigSchema(moduleName
, schema
): void
This defines a configuration schema for a module. The schema tells the configuration system how the module can be configured. It specifies what makes configuration valid or invalid.
See Configuration System for more information about defining a config schema.
Name | Type | Description |
---|---|---|
moduleName |
string |
Name of the module the schema is being defined for. Generally should be the one in which the defineConfigSchema call takes place. |
schema |
ConfigSchema |
The config schema for the module |
void
packages/framework/esm-config/src/module-config/module-config.ts:193
▸ defineExtensionConfigSchema(extensionName
, schema
): void
This defines a configuration schema for an extension. When a schema is defined for an extension, that extension will receive the configuration corresponding to that schema, rather than the configuration corresponding to the module in which it is defined.
The schema tells the configuration system how the module can be configured. It specifies what makes configuration valid or invalid.
See Configuration System for more information about defining a config schema.
Name | Type | Description |
---|---|---|
extensionName |
string |
Name of the extension the schema is being defined for. Should match the name of one of the extensions entries being returned by setupOpenMRS . |
schema |
ConfigSchema |
The config schema for the extension |
void
packages/framework/esm-config/src/module-config/module-config.ts:218
▸ getConfig(moduleName
): Promise
<Config
>
A promise-based way to access the config as soon as it is fully loaded. If it is already loaded, resolves the config in its present state.
In general you should use the Unistore-based API provided by
getConfigStore
, which allows creating a subscription so that you always
have the latest config. If using React, just use useConfig
.
This is a useful function if you need to get the config in the course of the execution of a function.
Name | Type | Description |
---|---|---|
moduleName |
string |
The name of the module for which to look up the config |
Promise
<Config
>
packages/framework/esm-config/src/module-config/module-config.ts:254
▸ provide(config
, sourceName?
): void
Name | Type | Default value |
---|---|---|
config |
Config |
undefined |
sourceName |
string |
"provided" |
void
packages/framework/esm-config/src/module-config/module-config.ts:234
▸ useConfig(): Object
Use this React Hook to obtain your module's configuration.
Object
Name | Type | Description |
---|---|---|
constructor |
Function |
The initial value of Object.prototype.constructor is the standard built-in Object constructor. |
hasOwnProperty |
(v : PropertyKey ) => boolean |
Determines whether an object has a property with the specified name. |
isPrototypeOf |
(v : Object ) => boolean |
Determines whether an object exists in another object's prototype chain. |
propertyIsEnumerable |
(v : PropertyKey ) => boolean |
Determines whether a specified property is enumerable. |
toLocaleString |
() => string |
Returns a date converted to a string using the current locale. |
toString |
() => string |
Returns a string representation of an object. |
valueOf |
() => Object |
Returns the primitive value of the specified object. |
packages/framework/esm-react-utils/src/useConfig.ts:163
▸ Const
inRange(min
, max
): Validator
Verifies that the value is between the provided minimum and maximum
Name | Type | Description |
---|---|---|
min |
number |
Minimum acceptable value |
max |
number |
Maximum acceptable value |
packages/framework/esm-config/src/validators/validators.ts:10
▸ Const
isUrl(value
): string
| void
Verifies that a string contains only the default URL template parameters.
category
Navigation
Name | Type |
---|---|
value |
any |
string
| void
packages/framework/esm-config/src/validators/validators.ts:56
▸ Const
isUrlWithTemplateParameters(allowedTemplateParameters
): Validator
Verifies that a string contains only the default URL template
parameters, plus any specified in allowedTemplateParameters
.
category
Navigation
Name | Type | Description |
---|---|---|
allowedTemplateParameters |
string [] |
To be added to openmrsBase and openmrsSpaBase |
packages/framework/esm-config/src/validators/validators.ts:24
▸ validator(validationFunction
, message
): Validator
Name | Type |
---|---|
validationFunction |
ValidatorFunction |
message |
string |
packages/framework/esm-config/src/validators/validator.ts:4
▸ formatDate(date
, options?
): string
Formats the input date according to the current locale and the given options.
Default options:
- mode: "standard",
- time: "for today",
- day: true,
- year: true
If the date is today then "Today" is produced (in the locale language).
When time is included, it is appended with a comma and a space. This
agrees with the output of Date.prototype.toLocaleString
for most
locales.
Name | Type |
---|---|
date |
Date |
options? |
Partial <FormatDateOptions > |
string
packages/framework/esm-utils/src/omrs-dates.ts:182
▸ formatDatetime(date
, options?
): string
Formats the input into a string showing the date and time, according
to the current locale. The mode
parameter is as described for
formatDate
.
This is created by concatenating the results of formatDate
and formatTime
with a comma and space. This agrees with the
output of Date.prototype.toLocaleString
for most locales.
Name | Type |
---|---|
date |
Date |
options? |
Partial <Omit <FormatDateOptions , "time" >> |
string
packages/framework/esm-utils/src/omrs-dates.ts:249
▸ formatTime(date
): string
Formats the input as a time, according to the current locale. 12-hour or 24-hour clock depends on locale.
Name | Type |
---|---|
date |
Date |
string
packages/framework/esm-utils/src/omrs-dates.ts:233
▸ isOmrsDateStrict(omrsPayloadString
): boolean
This function is STRICT on checking whether a date string is the openmrs format. The format should be YYYY-MM-DDTHH:mm:ss.SSSZZ
Name | Type |
---|---|
omrsPayloadString |
string |
boolean
packages/framework/esm-utils/src/omrs-dates.ts:27
▸ isOmrsDateToday(date
): boolean
Name | Type | Description |
---|---|---|
date |
DateInput |
Checks if the provided date is today. |
boolean
packages/framework/esm-utils/src/omrs-dates.ts:64
▸ parseDate(dateString
): Date
Utility function to parse an arbitrary string into a date.
Uses dayjs(dateString)
.
Name | Type |
---|---|
dateString |
string |
Date
packages/framework/esm-utils/src/omrs-dates.ts:136
▸ toDateObjectStrict(omrsDateString
): Date
| null
Converts the object to a date object if it is a valid ISO date time string.
Name | Type |
---|---|
omrsDateString |
string |
Date
| null
packages/framework/esm-utils/src/omrs-dates.ts:71
▸ toOmrsDateFormat(date
, format?
): string
deprecated
use formatDate(date)
Formats the input as a date string. By default the format "YYYY-MMM-DD" is used.
Name | Type | Default value |
---|---|---|
date |
DateInput |
undefined |
format |
string |
"YYYY-MMM-DD" |
string
packages/framework/esm-utils/src/omrs-dates.ts:128
▸ toOmrsDayDateFormat(date
): string
deprecated
use formatDate(date, "wide")
Formats the input as a date string using the format "DD - MMM - YYYY".
Name | Type |
---|---|
date |
DateInput |
string
packages/framework/esm-utils/src/omrs-dates.ts:112
▸ toOmrsIsoString(date
, toUTC?
): string
Formats the input as a date time string using the format "YYYY-MM-DDTHH:mm:ss.SSSZZ".
Name | Type | Default value |
---|---|---|
date |
DateInput |
undefined |
toUTC |
boolean |
false |
string
packages/framework/esm-utils/src/omrs-dates.ts:82
▸ toOmrsTimeString(date
): string
deprecated
use formatTime
Formats the input as a time string using the format "HH:mm A".
Name | Type |
---|---|
date |
DateInput |
string
packages/framework/esm-utils/src/omrs-dates.ts:104
▸ toOmrsTimeString24(date
): string
deprecated
use formatTime
Formats the input as a time string using the format "HH:mm".
Name | Type |
---|---|
date |
DateInput |
string
packages/framework/esm-utils/src/omrs-dates.ts:96
▸ toOmrsYearlessDateFormat(date
): string
deprecated
use formatDate(date, "no year")
Formats the input as a date string using the format "DD-MMM".
Name | Type |
---|---|
date |
DateInput |
string
packages/framework/esm-utils/src/omrs-dates.ts:120
▸ createErrorHandler(): (incomingErr
: any
) => void
fn
▸ (incomingErr
): void
Name | Type |
---|---|
incomingErr |
any |
void
packages/framework/esm-error-handling/src/index.ts:24
▸ reportError(err
): void
Name | Type |
---|---|
err |
any |
void
packages/framework/esm-error-handling/src/index.ts:17
▸ attach(slotName
, extensionId
): void
Attach an extension to an extension slot.
This will cause the extension to be rendered into the specified
extension slot, unless it is removed by configuration. Using
attach
is an alternative to specifying the slot
or slots
in the extension declaration.
It is particularly useful when creating a slot into which you want to render an existing extension. This enables you to do so without modifying the extension's declaration, which may be impractical or inappropriate, for example if you are writing a module for a specific implementation.
Name | Type | Description |
---|---|---|
slotName |
string |
a name uniquely identifying the slot |
extensionId |
string |
an extension name, with an optional #-suffix to distinguish it from other instances of the same extension attached to the same slot. |
void
packages/framework/esm-extensions/src/extensions.ts:172
▸ detach(extensionSlotName
, extensionId
): void
Avoid using this. Extension attachments should be considered declarative.
Name | Type |
---|---|
extensionSlotName |
string |
extensionId |
string |
void
packages/framework/esm-extensions/src/extensions.ts:203
▸ detachAll(extensionSlotName
): void
Avoid using this. Extension attachments should be considered declarative.
Name | Type |
---|---|
extensionSlotName |
string |
void
packages/framework/esm-extensions/src/extensions.ts:227
▸ getAssignedExtensions(slotName
): AssignedExtension
[]
Name | Type |
---|---|
slotName |
string |
packages/framework/esm-extensions/src/extensions.ts:328
▸ getConnectedExtensions(assignedExtensions
, online?
): ConnectedExtension
[]
Filters a list of extensions according to whether they support the current connectivity status.
Name | Type | Default value | Description |
---|---|---|---|
assignedExtensions |
AssignedExtension [] |
undefined |
The list of extensions to filter. |
online |
null | boolean |
null |
Whether the app is currently online. If null , uses navigator.onLine . |
A list of extensions that should be rendered
packages/framework/esm-extensions/src/extensions.ts:285
▸ getExtensionNameFromId(extensionId
): string
Given an extension ID, which is a string uniquely identifying an instance of an extension within an extension slot, this returns the extension name.
example
getExtensionNameFromId("foo#bar")
--> "foo"
getExtensionNameFromId("baz")
--> "baz"
Name | Type |
---|---|
extensionId |
string |
string
packages/framework/esm-extensions/src/extensions.ts:116
▸ Const
getExtensionStore(): Store
<ExtensionStore
>
This returns a store that modules can use to get information about the state of the extension system.
Store
<ExtensionStore
>
packages/framework/esm-extensions/src/store.ts:129
▸ renderExtension(domElement
, extensionSlotName
, extensionSlotModuleName
, extensionId
, renderFunction?
, additionalProps?
): CancelLoading
Mounts into a DOM node (representing an extension slot) a lazy-loaded component from any frontend module that registered an extension component for this slot.
Name | Type |
---|---|
domElement |
HTMLElement |
extensionSlotName |
string |
extensionSlotModuleName |
string |
extensionId |
string |
renderFunction |
(lifecycle : Lifecycle ) => Lifecycle |
additionalProps |
Record <string , any > |
packages/framework/esm-extensions/src/render.ts:17
▸ useAssignedExtensionIds(slotName
): string
[]
Gets the assigned extension ids for a given extension slot name. Does not consider if offline or online.
deprecated
Use useAssignedExtensions
Name | Type | Description |
---|---|---|
slotName |
string |
The name of the slot to get the assigned IDs for. |
string
[]
packages/framework/esm-react-utils/src/useAssignedExtensionIds.ts:13
▸ useAssignedExtensions(slotName
): AssignedExtension
[]
Gets the assigned extensions for a given extension slot name. Does not consider if offline or online.
Name | Type | Description |
---|---|---|
slotName |
string |
The name of the slot to get the assigned extensions for. |
packages/framework/esm-react-utils/src/useAssignedExtensions.ts:15
▸ useConnectedExtensions(slotName
): ConnectedExtension
[]
Gets the assigned extension for a given extension slot name. Considers if offline or online.
Name | Type | Description |
---|---|---|
slotName |
string |
The name of the slot to get the assigned extensions for. |
packages/framework/esm-react-utils/src/useConnectedExtensions.ts:15
▸ useExtensionSlotMeta<T
>(extensionSlotName
): Object
Extract meta data from all extension for a given extension slot.
Name | Type |
---|---|
T |
ExtensionMeta |
Name | Type |
---|---|
extensionSlotName |
string |
Object
packages/framework/esm-react-utils/src/useExtensionSlotMeta.ts:10
▸ Const
useExtensionStore(): T
T
packages/framework/esm-react-utils/src/useExtensionStore.ts:5
▸ Const
useExtensionStore(actions
): T
& BoundActions
Name | Type |
---|---|
actions |
Actions |
T
& BoundActions
packages/framework/esm-react-utils/src/useExtensionStore.ts:5
▸ Const
useExtensionStore(actions?
): T
& BoundActions
Name | Type |
---|---|
actions? |
Actions |
T
& BoundActions
packages/framework/esm-react-utils/src/useExtensionStore.ts:5
▸ Const
getAsyncExtensionLifecycle<T
>(lazy
, options
): () => Promise
<ReactAppOrParcel
<any
>>
deprecated
Use getAsyncLifecycle instead.
Name |
---|
T |
Name | Type |
---|---|
lazy |
() => Promise <{ default : ComponentType <T > }> |
options |
ComponentDecoratorOptions |
fn
▸ (): Promise
<ReactAppOrParcel
<any
>>
Promise
<ReactAppOrParcel
<any
>>
packages/framework/esm-react-utils/src/getLifecycle.ts:39
▸ getAsyncLifecycle<T
>(lazy
, options
): () => Promise
<ReactAppOrParcel
<any
>>
Name |
---|
T |
Name | Type |
---|---|
lazy |
() => Promise <{ default : ComponentType <T > }> |
options |
ComponentDecoratorOptions |
fn
▸ (): Promise
<ReactAppOrParcel
<any
>>
Promise
<ReactAppOrParcel
<any
>>
packages/framework/esm-react-utils/src/getLifecycle.ts:21
▸ getLifecycle<T
>(Component
, options
): ReactAppOrParcel
<any
>
Name |
---|
T |
Name | Type |
---|---|
Component |
ComponentType <T > |
options |
ComponentDecoratorOptions |
ReactAppOrParcel
<any
>
packages/framework/esm-react-utils/src/getLifecycle.ts:10
▸ getSyncLifecycle<T
>(Component
, options
): () => Promise
<ReactAppOrParcel
<any
>>
Name |
---|
T |
Name | Type |
---|---|
Component |
ComponentType <T > |
options |
ComponentDecoratorOptions |
fn
▸ (): Promise
<ReactAppOrParcel
<any
>>
Promise
<ReactAppOrParcel
<any
>>
packages/framework/esm-react-utils/src/getLifecycle.ts:29
▸ interpolateString(template
, params
): string
Interpolates values of params
into the template
string.
Useful for additional template parameters in URLs.
Example usage:
navigate({
to: interpolateString(
config.links.patientChart,
{ patientUuid: patient.uuid }
)
});
Name | Type | Description |
---|---|---|
template |
string |
With optional params wrapped in ${ } |
params |
object |
Values to interpolate into the string template |
string
packages/framework/esm-config/src/navigation/interpolate-string.ts:41
▸ interpolateUrl(template
): string
Interpolates a string with openmrsBase and openmrsSpaBase.
Useful for accepting ${openmrsBase}
or ${openmrsSpaBase}
template
parameters in configurable URLs.
Name | Type | Description |
---|---|---|
template |
string |
A string to interpolate |
string
packages/framework/esm-config/src/navigation/interpolate-string.ts:15
▸ navigate(to
): void
Calls location.assign
for non-SPA paths and navigateToUrl for SPA paths
Example usage:
const config = getConfig();
const submitHandler = () => {
navigate({ to: config.links.submitSuccess });
};
Name | Type | Description |
---|---|---|
to |
NavigateOptions |
The target path or URL. Supports templating with 'openmrsBase' and 'openmrsSpaBase'. For example, ${openmrsSpaBase}/home will resolve to /openmrs/spa/home for implementations using the standard OpenMRS and SPA base paths. |
void
packages/framework/esm-config/src/navigation/navigate.ts:29
▸ beginEditSynchronizationItem(id
): Promise
<void
>
Triggers an edit flow for the given synchronization item. If this is not possible, throws an error.
Name | Type | Description |
---|---|---|
id |
number |
The ID of the synchronization item to be edited. |
Promise
<void
>
packages/framework/esm-offline/src/sync.ts:355
▸ canBeginEditSynchronizationItemsOfType(type
): boolean
Returns whether editing synchronization items of the given type is supported by the currently registered synchronization handlers.
Name | Type | Description |
---|---|---|
type |
string |
The identifying type of the synchronization item which should be edited. |
boolean
packages/framework/esm-offline/src/sync.ts:345
▸ deleteSynchronizationItem(id
): Promise
<void
>
Deletes a queued up sync item with the given ID.
Name | Type | Description |
---|---|---|
id |
number |
The ID of the synchronization item to be deleted. |
Promise
<void
>
packages/framework/esm-offline/src/sync.ts:375
▸ generateOfflineUuid(): string
Generates a UUID-like string which is used for uniquely identifying objects while offline.
string
packages/framework/esm-offline/src/uuid.ts:7
▸ getCurrentOfflineMode(): OfflineModeResult
packages/framework/esm-offline/src/mode.ts:49
▸ getOfflinePatientDataStore(): Store
<OfflinePatientDataSyncStore
>
Store
<OfflinePatientDataSyncStore
>
packages/framework/esm-offline/src/offline-patient-data.ts:86
▸ getSynchronizationItem<T
>(id
): Promise
<SyncItem
<T
> | undefined
>
Returns a queued sync item with the given ID or undefined
if no such item exists.
Name | Type |
---|---|
T |
any |
Name | Type | Description |
---|---|---|
id |
number |
The ID of the requested sync item. |
Promise
<SyncItem
<T
> | undefined
>
packages/framework/esm-offline/src/sync.ts:334
▸ getSynchronizationItems<T
>(type
): Promise
<T
[]>
Returns all currently queued up sync items of the currently signed in user.
Name |
---|
T |
Name | Type | Description |
---|---|---|
type |
string |
The identifying type of the synchronization items to be returned. |
Promise
<T
[]>
packages/framework/esm-offline/src/sync.ts:325
▸ isOfflineUuid(uuid
): boolean
Checks whether the given string has the format of an offline UUID generated by generateOfflineUuid
Name | Type |
---|---|
uuid |
string |
boolean
packages/framework/esm-offline/src/uuid.ts:12
▸ loadPersistedPatientDataSyncState(): Promise
<void
>
Promise
<void
>
packages/framework/esm-offline/src/offline-patient-data.ts:200
▸ messageOmrsServiceWorker(message
): Promise
<MessageServiceWorkerResult
<any
>>
Sends the specified message to the application's service worker.
Name | Type | Description |
---|---|---|
message |
KnownOmrsServiceWorkerMessages |
The message to be sent. |
Promise
<MessageServiceWorkerResult
<any
>>
A promise which completes when the message has been successfully processed by the Service Worker.
packages/framework/esm-offline/src/service-worker-messaging.ts:11
▸ queueSynchronizationItem<T
>(type
, content
, descriptor?
): Promise
<number
>
Enqueues a new item in the sync queue and associates the item with the currently signed in user.
Name |
---|
T |
Name | Type | Description |
---|---|---|
type |
string |
The identifying type of the synchronization item. |
content |
T |
The actual data to be synchronized. |
descriptor? |
QueueItemDescriptor |
An optional descriptor providing additional metadata about the sync item. |
Promise
<number
>
packages/framework/esm-offline/src/sync.ts:293
▸ registerOfflinePatientHandler(identifier
, handler
): void
Attempts to add the specified patient handler registration to the list of offline patient handlers.
Name | Type | Description |
---|---|---|
identifier |
string |
A key which uniquely identifies the registration. |
handler |
OfflinePatientDataSyncHandler |
The patient handler registration to be registered. |
void
true
if the registration was successfully made; false
if another registration with
the same identifier has already been registered before.
packages/framework/esm-offline/src/offline-patient-data.ts:97
▸ setupOfflineSync<T
>(type
, dependsOn
, process
, options?
): void
Registers a new synchronization handler which is able to synchronize data of a specific type.
Name |
---|
T |
Name | Type | Description |
---|---|---|
type |
string |
The identifying type of the synchronization items which can be handled by this handler. |
dependsOn |
string [] |
An array of other sync item types which must be synchronized before this handler can synchronize its own data. Items of these types are effectively dependencies of the data synchronized by this handler. |
process |
ProcessSyncItem <T > |
A function which, when invoked, performs the actual client-server synchronization of the given item (which is the actual data to be synchronized). |
options |
SetupOfflineSyncOptions <T > |
Additional options which can optionally be provided when setting up a synchronization callback for a specific synchronization item type. |
void
packages/framework/esm-offline/src/sync.ts:390
▸ subscribeConnectivity(cb
): () => void
Name | Type |
---|---|
cb |
(ev : ConnectivityChangedEvent ) => void |
fn
▸ (): void
void
packages/framework/esm-globals/src/events.ts:24
▸ subscribeConnectivityChanged(cb
): () => void
Name | Type |
---|---|
cb |
(ev : ConnectivityChangedEvent ) => void |
fn
▸ (): void
void
packages/framework/esm-globals/src/events.ts:14
▸ subscribePrecacheStaticDependencies(cb
): () => void
Name | Type |
---|---|
cb |
(data : PrecacheStaticDependenciesEvent ) => void |
fn
▸ (): void
void
packages/framework/esm-globals/src/events.ts:45
▸ syncOfflinePatientData(patientUuid
): Promise
<void
>
Notifies all registered offline patient handlers that a new patient must be made available offline.
Name | Type |
---|---|
patientUuid |
string |
Promise
<void
>
A promise which resolves once all registered handlers have finished synchronizing.
packages/framework/esm-offline/src/offline-patient-data.ts:112
▸ useConnectivity(): boolean
boolean
packages/framework/esm-react-utils/src/useConnectivity.ts:5
▸ createGlobalStore<TState
>(name
, initialState
): Store
<TState
>
Creates a Unistore store.
Name |
---|
TState |
Name | Type | Description |
---|---|---|
name |
string |
A name by which the store can be looked up later. Must be unique across the entire application. |
initialState |
TState |
An object which will be the initial state of the store. |
Store
<TState
>
The newly created store.
packages/framework/esm-state/src/state.ts:19
▸ createUseStore<T
>(store
): () => T
(actions
: Actions
) => T
& BoundActions
(actions?
: Actions
) => T
& BoundActions
Avoid this; generally prefer to have clients use useStore(yourStore)
Name |
---|
T |
Name | Type |
---|---|
store |
Store <T > |
fn
▸ (): T
T
▸ (actions
): T
& BoundActions
Name | Type |
---|---|
actions |
Actions |
T
& BoundActions
▸ (actions?
): T
& BoundActions
Name | Type |
---|---|
actions? |
Actions |
T
& BoundActions
packages/framework/esm-react-utils/src/createUseStore.ts:23
▸ getAppState(): Store
<AppState
>
Store
<AppState
>
The store named app
.
packages/framework/esm-state/src/state.ts:86
▸ getGlobalStore<TState
>(name
, fallbackState?
): Store
<TState
>
Returns the existing store named name
,
or creates a new store named name
if none exists.
Name | Type |
---|---|
TState |
any |
Name | Type | Description |
---|---|---|
name |
string |
The name of the store to look up. |
fallbackState? |
TState |
The initial value of the new store if no store named name exists. |
Store
<TState
>
The found or newly created store.
packages/framework/esm-state/src/state.ts:56
▸ subscribeTo<T
, U
>(store
, select
, handle
): Unsubscribe
Name |
---|
T |
U |
Name | Type |
---|---|
store |
Store <T > |
select |
(state : T ) => U |
handle |
(subState : U ) => void |
Unsubscribe
packages/framework/esm-state/src/state.ts:90
▸ useStore<T
, U
>(store
): T
Name |
---|
T |
U |
Name | Type |
---|---|
store |
Store <T > |
T
packages/framework/esm-react-utils/src/useStore.ts:23
▸ useStore<T
, U
>(store
, select
): U
Name |
---|
T |
U |
Name | Type |
---|---|
store |
Store <T > |
select |
(state : T ) => U |
U
packages/framework/esm-react-utils/src/useStore.ts:24
▸ useStore<T
, U
>(store
, select
, actions
): T
& BoundActions
Name |
---|
T |
U |
Name | Type |
---|---|
store |
Store <T > |
select |
undefined |
actions |
Actions |
T
& BoundActions
packages/framework/esm-react-utils/src/useStore.ts:25
▸ useStore<T
, U
>(store
, select
, actions
): U
& BoundActions
Name |
---|
T |
U |
Name | Type |
---|---|
store |
Store <T > |
select |
(state : T ) => U |
actions |
Actions |
U
& BoundActions
packages/framework/esm-react-utils/src/useStore.ts:30
▸ useStoreWithActions<T
>(store
, actions
): T
& BoundActions
Name |
---|
T |
Name | Type |
---|---|
store |
Store <T > |
actions |
Actions |
T
& BoundActions
packages/framework/esm-react-utils/src/useStore.ts:52
▸ showModal(extensionId
, props?
, onClose?
): () => void
Shows the provided extension component in a modal dialog.
Name | Type | Description |
---|---|---|
extensionId |
string |
The id of the extension to show. |
props |
Record <string , any > |
The optional props to provide to the extension. |
onClose |
() => void |
The optional notification to receive when the modal is closed. |
fn
The dispose function to force closing the modal dialog.
▸ (): void
void
packages/framework/esm-styleguide/src/modals/index.tsx:164
▸ showNotification(notification
): void
Displays an inline notification in the UI.
Name | Type | Description |
---|---|---|
notification |
NotificationDescriptor |
The description of the notification to display. |
void
packages/framework/esm-styleguide/src/notifications/index.tsx:41
▸ showToast(toast
): void
Displays a toast notification in the UI.
Name | Type | Description |
---|---|---|
toast |
ToastDescriptor |
The description of the toast to display. |
void
packages/framework/esm-styleguide/src/toasts/index.tsx:35
▸ subscribeNotificationShown(cb
): () => void
Name | Type |
---|---|
cb |
(data : ShowNotificationEvent ) => void |
fn
▸ (): void
void
packages/framework/esm-globals/src/events.ts:93
▸ subscribeToastShown(cb
): () => void
Name | Type |
---|---|
cb |
(data : ShowToastEvent ) => void |
fn
▸ (): void
void
packages/framework/esm-globals/src/events.ts:102
▸ useBodyScrollLock(active
): void
Name | Type |
---|---|
active |
boolean |
void
packages/framework/esm-react-utils/src/useBodyScrollLock.ts:4
▸ useLayoutType(): LayoutType
packages/framework/esm-react-utils/src/useLayoutType.ts:23
▸ useOnClickOutside<T
>(handler
, active?
): RefObject
<T
>
Name | Type |
---|---|
T |
extends HTMLElement = HTMLElement |
Name | Type | Default value |
---|---|---|
handler |
(event : Event ) => void |
undefined |
active |
boolean |
true |
RefObject
<T
>
packages/framework/esm-react-utils/src/useOnClickOutside.tsx:4
▸ usePagination<T
>(data?
, resultsPerPage?
): Object
Name |
---|
T |
Name | Type | Default value |
---|---|---|
data |
T [] |
[] |
resultsPerPage |
number |
defaultResultsPerPage |
Object
Name | Type |
---|---|
currentPage |
number |
paginated |
boolean |
results |
T [] |
showNextButton |
boolean |
showPreviousButton |
boolean |
totalPages |
number |
goTo |
(page : number ) => void |
goToNext |
() => void |
goToPrevious |
() => void |
packages/framework/esm-react-utils/src/usePagination.ts:6
▸ age(dateString
): string
Gets a human readable age represention of the provided date string.
Name | Type | Description |
---|---|---|
dateString |
string |
The stringified date. |
string
A human-readable string version of the age.
packages/framework/esm-utils/src/age-helpers.tsx:39
▸ daysIntoYear(date
): number
Gets the number of days in the year of the given date.
Name | Type | Description |
---|---|---|
date |
Date |
The date to compute the days within the year. |
number
The number of days.
packages/framework/esm-utils/src/age-helpers.tsx:8
▸ isSameDay(firstDate
, secondDate
): boolean
Checks if two dates are representing the same day.
Name | Type | Description |
---|---|---|
firstDate |
Date |
The first date. |
secondDate |
Date |
The second date. |
boolean
True if both are located on the same day.
packages/framework/esm-utils/src/age-helpers.tsx:25
▸ isVersionSatisfied(requiredVersion
, installedVersion
): boolean
Name | Type |
---|---|
requiredVersion |
string |
installedVersion |
string |
boolean
packages/framework/esm-utils/src/version.ts:22
▸ retry<T
>(fn
, options?
): Promise
<T
>
Executes the specified function and retries executing on failure with a custom backoff strategy defined by the options.
If not configured otherwise, this function uses the following default options:
- Retries 5 times beyond the initial attempt.
- Uses an exponential backoff starting with an initial delay of 1000ms.
throws
Rethrows the final error of running fn
when the function stops retrying.
Name |
---|
T |
Name | Type | Description |
---|---|---|
fn |
() => Promise <T > |
The function to be executed and retried on failure. |
options |
RetryOptions |
Additional options which configure the retry behavior. |
Promise
<T
>
The result of successfully executing fn
.
packages/framework/esm-utils/src/retry.ts:40
▸ translateFrom(moduleName
, key
, fallback?
, options?
): string
Name | Type |
---|---|
moduleName |
string |
key |
string |
fallback? |
string |
options? |
object |
string