Skip to content

CharlieHess/electron-fetch-transport

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

electron-fetch-transport

A transport for node-slack-sdk that uses Electron's net module. You can use this in place of the default request transport to allow the the web & rtm clients to reap the benefits of Chromium's networking stack from Electron's main process.

Installation

npm i electron-fetch-transport --save

Usage

import { RtmClient } from '@slack/client';
import netTransport from 'electron-fetch-transport';

// Use Electron's `net` module for requests
const rtm = new RtmClient(token, {
  transport: netTransport,
  ...
});