npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

fjson

v0.2.1b

Published

FunkyJSON is an extension of JSON that allows for the transferring of functions and Regular Expressionsvia JSON.

Downloads

10

Readme

FunkyJSON

FunkyJSON (FJSON) is an extension of the JSON that allows for the transmission of functions via JSON. The need to serialize functions into JSON was necessary to solve certains issues we were having so we developed a mean to serialize functions and parse them. FJSON is a very simple library.

How It Works

FJSON takes a function and converts into a serializable object. For example, assume the object:

var hello = function(name) {
  console.log(name);
}; 

Would be converted to the following serializable object:

{
  "FUNCTION": true,
  "params": [""],
  "body": "console.log(name);"
}   

How to Use It

Installation

Install via NPM easily with npm install fjson or globally with npm install -g fjson

Usage

Once installed require in your code file easily: var FJSON = require("fjson");

From here you can use the variable you stored the library into (in the above example it's FJSON) or you can use the same functions on the JSON object.

Use FJSON.funkify(obj); to serialize the object as a string (including functions) and use FJSON.unfunkify(str); to convert a FJSON string into an object.

FJSON should be usable in a browser but this is untested.

Author

Brandon Buck [email protected]

License

AGPL v3

This software is licensed under the Affero General Public License which can be found here.