Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@uxland-admin/ip-context-info

Package Overview
Dependencies
Maintainers
1
Versions
43
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@uxland-admin/ip-context-info - npm Package Compare versions

Comparing version 1.0.8 to 1.0.9

19

app/context-info/fetch-context-info.js
import isAsyncStateStale from "@uxland/uxl-redux/is-async-stale";
import { FETCH_CONTEXT_INFO } from "../../state/context-info/reducer";
import { store } from '@uxland/uxl-prism/store';
import { createAsyncActions } from "@uxland/uxl-redux/create-async-actions";
import { icsFetchClient } from "@uxland-admin/ics-process-core/ics-fetch-client";
import { patientContextSelector } from "@uxland-admin/ics-process-core/patient-context/patient-context-selector";
import { contextInfoSelector } from "./context-info-view";
export const asyncAction = async (action, fn, store, meta) => {
let started = window.performance.now();
let actions = createAsyncActions(action);
try {
store.dispatch({ type: actions.started, meta: meta });
let result = await fn();
store.dispatch({ type: actions.succeeded, payload: result, meta: meta });
}
catch (e) {
store.dispatch({ type: actions.failed, payload: e, meta: meta });
}
finally {
store.dispatch({ type: actions.ended, payload: { elapsed: window.performance.now() - started }, meta: meta });
}
};
import { performAsyncAction } from '@uxland/uxl-redux/perform-async-action';
export const fetchContextInfo = () => {

@@ -29,5 +14,5 @@ let patientContext = patientContextSelector(store.getState());

let uri = `/patient/${patientContext.center}/${patientContext.patient}/${patientContext.case}/${patientContext.movement}/context-info`;
return asyncAction(FETCH_CONTEXT_INFO, () => icsFetchClient.fetch(uri), store);
return performAsyncAction(FETCH_CONTEXT_INFO, () => icsFetchClient.fetch(uri), store);
}
}
};

4

index.d.ts

@@ -88,5 +88,3 @@ declare module '@uxland-admin/ip-context-info/constants' {

declare module '@uxland-admin/ip-context-info/app/context-info/fetch-context-info' {
import { Store } from "redux";
export const asyncAction: <T = any>(action: string, fn: () => Promise<T>, store: Store<any, import("redux").AnyAction>, meta?: any) => Promise<void>;
export const fetchContextInfo: () => Promise<void>;
export const fetchContextInfo: () => Promise<any>;

@@ -93,0 +91,0 @@ }

{
"name": "@uxland-admin/ip-context-info",
"description": "ICS Process - Context info",
"version": "1.0.8",
"version": "1.0.9",
"main": "index.js",

@@ -6,0 +6,0 @@ "repository": {

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc