Socket
Socket
Sign inDemoInstall

@jvlk/fp-ts-fetch

Package Overview
Dependencies
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@jvlk/fp-ts-fetch - npm Package Compare versions

Comparing version 1.1.0 to 1.1.1

7

CHANGELOG.md

@@ -0,1 +1,8 @@

## [1.1.1](https://github.com/jderochervlk/fp-ts-fetch/compare/v1.1.0...v1.1.1) (2022-11-08)
### Bug Fixes
* remove lib from fp-ts imports ([798900b](https://github.com/jderochervlk/fp-ts-fetch/commit/798900bf1b33c3860a8c8ec1309b4e8c21264fad))
# [1.1.0](https://github.com/jderochervlk/fp-ts-fetch/compare/v1.0.0...v1.1.0) (2022-11-07)

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

8

dist/index.js

@@ -1,3 +0,3 @@

var $8zHUo$fptslibfunction = require("fp-ts/lib/function");
var $8zHUo$fptslibTaskEither = require("fp-ts/lib/TaskEither");
var $8zHUo$fptsfunction = require("fp-ts/function");
var $8zHUo$fptsTaskEither = require("fp-ts/TaskEither");

@@ -13,3 +13,3 @@ function $parcel$export(e, n, v, s) {

function $e3305e211d4f257d$export$2e2bcd8739ae039(input, init) {
return (0, $8zHUo$fptslibfunction.pipe)((0, $8zHUo$fptslibTaskEither.tryCatch)(()=>fetch(input, init), (e)=>Error(`fetch failed: ${e}`)), (0, $8zHUo$fptslibTaskEither.chainW)((res)=>res.ok ? (0, $8zHUo$fptslibTaskEither.right)(res) : (0, $8zHUo$fptslibTaskEither.left)(res)));
return (0, $8zHUo$fptsfunction.pipe)((0, $8zHUo$fptsTaskEither.tryCatch)(()=>fetch(input, init), (e)=>Error(`fetch failed: ${e}`)), (0, $8zHUo$fptsTaskEither.chainW)((res)=>res.ok ? (0, $8zHUo$fptsTaskEither.right)(res) : (0, $8zHUo$fptsTaskEither.left)(res)));
}

@@ -22,3 +22,3 @@

function $4defa21c9f244d76$export$2e2bcd8739ae039(input, init) {
return (0, $8zHUo$fptslibfunction.pipe)((0, $e3305e211d4f257d$export$2e2bcd8739ae039)(input, init), (0, $8zHUo$fptslibTaskEither.chainW)((res)=>(0, $8zHUo$fptslibTaskEither.tryCatch)(()=>res.json(), (e)=>Error(`failed to parse response JSON: ${e}`))));
return (0, $8zHUo$fptsfunction.pipe)((0, $e3305e211d4f257d$export$2e2bcd8739ae039)(input, init), (0, $8zHUo$fptsTaskEither.chainW)((res)=>(0, $8zHUo$fptsTaskEither.tryCatch)(()=>res.json(), (e)=>Error(`failed to parse response JSON: ${e}`))));
}

@@ -25,0 +25,0 @@

@@ -1,3 +0,3 @@

import {pipe as $hgUW1$pipe} from "fp-ts/lib/function";
import {tryCatch as $hgUW1$tryCatch, chainW as $hgUW1$chainW, right as $hgUW1$right, left as $hgUW1$left} from "fp-ts/lib/TaskEither";
import {pipe as $hgUW1$pipe} from "fp-ts/function";
import {tryCatch as $hgUW1$tryCatch, chainW as $hgUW1$chainW, right as $hgUW1$right, left as $hgUW1$left} from "fp-ts/TaskEither";

@@ -4,0 +4,0 @@

@@ -11,3 +11,3 @@ /**

*/
export function safeFetch(input: RequestInfo | URL, init?: RequestInit | undefined): import("fp-ts/lib/TaskEither").TaskEither<Response | Error, Response>;
export function safeFetch(input: RequestInfo | URL, init?: RequestInit | undefined): import("fp-ts/TaskEither").TaskEither<Response | Error, Response>;
/**

@@ -23,4 +23,4 @@ * Safely fetch and attempt to parse the responses json.

*/
export function safeFetchJson<T>(input: RequestInfo | URL, init?: RequestInit | undefined): import("fp-ts/lib/TaskEither").TaskEither<Response | Error, T>;
export function safeFetchJson<T>(input: RequestInfo | URL, init?: RequestInit | undefined): import("fp-ts/TaskEither").TaskEither<Response | Error, T>;
//# sourceMappingURL=types.d.ts.map
{
"name": "@jvlk/fp-ts-fetch",
"version": "1.1.0",
"version": "1.1.1",
"description": "An fp-ts library to make it easy to work with fetch requests.",

@@ -5,0 +5,0 @@ "source": "src/index.ts",

@@ -5,4 +5,4 @@ /**

import { pipe } from 'fp-ts/lib/function'
import { tryCatch, chainW, right, left } from 'fp-ts/lib/TaskEither'
import { pipe } from 'fp-ts/function'
import { tryCatch, chainW, right, left } from 'fp-ts/TaskEither'

@@ -9,0 +9,0 @@ /**

@@ -1,7 +0,7 @@

import * as E from 'fp-ts/lib/Either'
import { isLeft, left, right } from 'fp-ts/lib/Either'
import { flow, pipe } from 'fp-ts/lib/function'
import * as TE from 'fp-ts/lib/TaskEither'
import * as E from 'fp-ts/Either'
import { isLeft, left, right } from 'fp-ts/Either'
import { flow, pipe } from 'fp-ts/function'
import * as TE from 'fp-ts/TaskEither'
import * as t from 'io-ts'
import { PathReporter } from 'io-ts/lib/PathReporter'
import { PathReporter } from 'io-ts/PathReporter'
import safeFetchJson from './safeFetchJson'

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

@@ -5,5 +5,5 @@ /**

import { pipe } from 'fp-ts/lib/function'
import { pipe } from 'fp-ts/function'
import safeFetch from './safeFetch'
import { tryCatch, chainW, right, left } from 'fp-ts/lib/TaskEither'
import { tryCatch, chainW, right, left } from 'fp-ts/TaskEither'

@@ -10,0 +10,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