clauneck
TypeScript icon, indicating that this package has built-in type declarations

0.1.12 • Public • Published

Clauneck

npm version codecov codebeat badge Greenkeeper badge MIT Build

Easy data for everyone, from everywhere. 🤤

Getting Started

Follow these simple instructions to get set up and ready to use Clauneck.

Via npm 📦

npm is the package manager for javascript

Read about npm here 💩

(I personally like using yarn 🙉 )

View the NPM page for Clauneck here 📄

Installing

Install Clauneck just like any other package: 📦

With NPM:

npm i -s clauneck

With Yarn:

yarn add clauneck

And use it:

const clauneck = require('clauneck');

Or, with TypeScript

import * as clauneck from 'clauneck'

or commands individually

import { users, get } from 'clauneck'

Usage

Assuming that clauneck is assigned to the clauneck variables 🙊

These all return promises and were created using async/await! ❤️

clauneck.get()

Gets data from a user 🌍

clauneck.get(
    path: string,
    options?: object
);

clauneck.set()

Merges, updates data 🎉

clauneck.set(
    path: string,
    psk: string,
    newData: any,
    options?: object
);

clauneck.clnk()

Sends a request to the Clauneck API

clauneck.clnk(
    cmd: string
    params?: object
);

clauneck.users()

Get the users! 🤼

clauneck.users();

clauneck.create()

Creates a new user 🎉

clauneck.create(
    name: string,
    psk: string
);

clauneck.psk()

Changes a user's password 🔑

clauneck.psk(
    handle: string,
    oldPsk: object,
    newPsk: object
);

clauneck.name()

Changes a user's name 🙌

clauneck.name(
    handle: string,
    psk: string,
    newName: string
);

clauneck.user()

Gets a user's id and name ❓

clauneck.user(
    handle: string
);

clauneck.check()

Checks a user's handle and password combo 🔐

clauneck.check(
    handle: string,
    psk: string
);

clauneck.exists()

Checks if a user exists 🐦

clauneck.exists(
    handle: string
);

clauneck.safeName()

⚠️ Returns a string, not a promise!

This makes a name safe for clauneck.

clauneck.safeName(
    name: string
);

clauneck.safeHandle()

⚠️ Returns a string, not a promise!

This makes a proper handle for clauneck.

clauneck.safeHandle(
    handle: string
);

Wrapping Up

Clauneck is an easy to use database for your data. 😘

If you catch something or want to work on Clauneck, it is open-sourced on GitHub!

Thanks for reading. 🎉🎉

Readme

Keywords

none

Package Sidebar

Install

npm i clauneck

Weekly Downloads

4

Version

0.1.12

License

MIT

Unpacked Size

20.3 kB

Total Files

17

Last publish

Collaborators

  • nilaeus