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

@equinor/fusion-framework-module-http

Package Overview
Dependencies
Maintainers
3
Versions
126
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@equinor/fusion-framework-module-http - npm Package Compare versions

Comparing version 0.4.0 to 0.5.0

16

CHANGELOG.md

@@ -6,2 +6,18 @@ # Change Log

# 0.5.0 (2022-08-08)
### Bug Fixes
* **module-http:** expose FetchRequest ([3d14ead](https://github.com/equinor/fusion-framework/commit/3d14ead0d78b36db091c6645ff1b69101e1f911f))
### Features
* **module-service-discovery:** resolve service to config ([3fa088d](https://github.com/equinor/fusion-framework/commit/3fa088d2ced8136447df6949928f1af9fc83407a))
# [0.4.0](https://github.com/equinor/fusion-framework/compare/@equinor/fusion-framework-module-http@0.3.10...@equinor/fusion-framework-module-http@0.4.0) (2022-08-04)

@@ -8,0 +24,0 @@

2

dist/types/index.d.ts

@@ -1,2 +0,2 @@

export { HttpClient, IHttpClient, FetchRequestInit } from './client';
export { HttpClient, IHttpClient, FetchRequestInit, FetchRequest } from './client';
export { HttpClientMsal } from './client-msal';

@@ -3,0 +3,0 @@ export * from './configurator';

@@ -5,5 +5,6 @@ import { HttpClientMsal } from './client-msal';

import type { Module, ModulesConfigType } from '@equinor/fusion-framework-module';
export declare type HttpModule = Module<'http', IHttpClientProvider<HttpClientMsal>, IHttpClientConfigurator<HttpClientMsal>>;
export declare type HttpModule = Module<'http', IHttpClientProvider, IHttpClientConfigurator>;
export declare type HttpMsalModule = Module<'http', IHttpClientProvider<HttpClientMsal>, IHttpClientConfigurator<HttpClientMsal>>;
export declare const module: HttpModule;
export declare const setupHttpModule: (config: ModulesConfigType<[HttpModule]>, callback: (config: IHttpClientConfigurator<HttpClientMsal>) => void) => void | Promise<void>;
export declare const setupHttpModule: (config: ModulesConfigType<[HttpModule]>, callback: (config: IHttpClientConfigurator) => void) => void | Promise<void>;
declare module '@equinor/fusion-framework-module' {

@@ -10,0 +11,0 @@ interface Modules {

@@ -1,2 +0,2 @@

import { HttpClient } from './client';
import { HttpClient, IHttpClient } from './client';
import { HttpClientOptions, IHttpClientConfigurator } from './configurator';

@@ -6,3 +6,3 @@ export declare class ClientNotFoundException extends Error {

}
export interface IHttpClientProvider<TClient extends HttpClient = HttpClient> {
export interface IHttpClientProvider<TClient extends IHttpClient = IHttpClient> {
hasClient(key: string): boolean;

@@ -13,3 +13,3 @@ createClient(key: string): TClient;

}
export declare class HttpClientProvider<TClient extends HttpClient> implements IHttpClientProvider<TClient> {
export declare class HttpClientProvider<TClient extends IHttpClient = IHttpClient> implements IHttpClientProvider<TClient> {
protected config: IHttpClientConfigurator<TClient>;

@@ -16,0 +16,0 @@ constructor(config: IHttpClientConfigurator<TClient>);

{
"name": "@equinor/fusion-framework-module-http",
"version": "0.4.0",
"version": "0.5.0",
"description": "",

@@ -32,3 +32,3 @@ "main": "dist/esm/index.js",

},
"gitHead": "65221b1abaf4e12d55349ddde5492c8facada168"
"gitHead": "472e06a77cfccc723b0fb88e628d10df18eab5e1"
}

@@ -6,3 +6,3 @@ /**

export { HttpClient, IHttpClient, FetchRequestInit } from './client';
export { HttpClient, IHttpClient, FetchRequestInit, FetchRequest } from './client';
export { HttpClientMsal } from './client-msal';

@@ -9,0 +9,0 @@

@@ -7,3 +7,5 @@ import { HttpClientMsal } from './client-msal';

export type HttpModule = Module<
export type HttpModule = Module<'http', IHttpClientProvider, IHttpClientConfigurator>;
export type HttpMsalModule = Module<
'http',

@@ -20,3 +22,3 @@ IHttpClientProvider<HttpClientMsal>,

configure: () => new HttpClientConfigurator(HttpClientMsal),
initialize: ({ http }): HttpClientProvider<HttpClientMsal> => new HttpClientProvider(http),
initialize: ({ http }): HttpClientProvider => new HttpClientProvider(http),
};

@@ -26,3 +28,3 @@

config: ModulesConfigType<[HttpModule]>,
callback: (config: IHttpClientConfigurator<HttpClientMsal>) => void
callback: (config: IHttpClientConfigurator) => void
): void | Promise<void> => {

@@ -29,0 +31,0 @@ callback(config.http);

@@ -1,2 +0,2 @@

import { HttpClient } from './client';
import { HttpClient, IHttpClient } from './client';
import { HttpClientOptions, IHttpClientConfigurator } from './configurator';

@@ -10,3 +10,3 @@

export interface IHttpClientProvider<TClient extends HttpClient = HttpClient> {
export interface IHttpClientProvider<TClient extends IHttpClient = IHttpClient> {
/** check if a client is configured */

@@ -42,3 +42,3 @@ hasClient(key: string): boolean;

export class HttpClientProvider<TClient extends HttpClient>
export class HttpClientProvider<TClient extends IHttpClient = IHttpClient>
implements IHttpClientProvider<TClient>

@@ -45,0 +45,0 @@ {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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