1.2.0 • Published 3 years ago

hastexp v1.2.0

Weekly downloads
15
License
MIT
Repository
github
Last release
3 years ago

HastExp

A simple hastebin package that lets you upload text to hastebin and make a link directly from writing code.

Methods

NametypeDESCRIPTION
messagestringMessage to post to hastebin
extension?extensionused to define which file extension you want to get the link in: Default is Javascript
NametypeDESCRIPTION
linkSlugstringlink slug to get a object contaning info about the haste (Must be 10 characters file extensions excluded)

usage

const { HastExp }  = require('hastexp')

//Instantiating a new HastExp object
const haste = new HastExp()

// makePost(message: string, extension?: Extension): Promise<any>

haste.makePost("This is a test")
.then(link => console.log(link))

// https://hastebin.com/imezuxulon.js


// fetchPost(linkSlug: string): Promise<any>

haste.fetchPost('imezuxulon')
.then(mes => console.log(mes))

// { data: 'This is a test', key: 'imezuxulon' }

Licence

This module is licensed under the MIT license.

1.2.0

3 years ago

1.1.0

3 years ago

1.0.0

3 years ago

0.0.9

3 years ago

0.0.8

3 years ago

0.0.7

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.4

3 years ago

0.0.1

3 years ago