phantasy-fetch

0.1.1 • Public • Published

phantasy-fetch

Build Status

Fetch implementation for Node using Phantasy data types

Installation

$ npm install --save phantasy-fetch

or

$ yarn add phantasy-fetch

Usage

import { FETCH, fetch } from 'phantasy-fetch';
import defaultFetch from 'phantasy-fetch';

// construct the request
let request = {
	method: 'GET',
	url: 'http://www.google.com/'
};

// generate the effectful Task
fetch(request)
	.runEff({ FETCH }) // handle effects
	.runTask( // run the resulting Task
		response => console.log(response),
		err => console.error(err)
	);

Readme

Keywords

Package Sidebar

Install

npm i phantasy-fetch

Weekly Downloads

0

Version

0.1.1

License

MIT

Last publish

Collaborators

  • tkuminecz