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

axislang

v0.9.3

Published

The official Axis Parser

Downloads

10

Readme

Axis Lang

travis logo

A data-driven syntax

What it does

Axis allows for quick access of data in JSON files or JavaScript data structures, ideal for APIs. Axis queries require the least possible amount of writing in order to access any JSON data

Examples

What it looks like

data -> attributes -> title

This expression will extract the title inside of attributes which is inside of data. Because Axis is designed to be ambiguous, attributes could be an array of objects and Axis will still work as it will identify the content that is parsing.

Axis Language specs for more examples

How to use it

Axis is used through a single method, simply provide an axis epression and a piece of data JSON string or Javascript object in order to query it

The following code will print all friends' names as an array

const axis = require('axislang')
const data = require('./input.json') // input.json link below

const allFriends = axis.parse('friends -> name', data) // Returns
// [ 'Britney Hensley', 'Annmarie Ryan', 'Hess Decker', 'Bolton Shaffer', 'Ruth Caldwell', 'Medina Kline', 'Tami Duncan', 'Lawrence Hooper', 'Esperanza Hickman', 'Winnie Stark', 'Madeleine Luna', 'Petty Vance', 'Mcgee Roy', 'Baldwin Waters', 'Marie Neal' ]
console.log(allFriends) 

Look at input.json

Axis abstracts away the process of extracting information from inside complex json objects and transforms into a single redable expression.

When to use it?

Axis is not designed to be perfomance oriented at least this parser in it's current state is not. However future implmentations may be, Axis is designed to avoid bugs and improve development speed, axis use a high level approach to accessing data where development speed may be more important than runtime speed.

Axis is extremely useful when working with any API or data source that uses JSON for data transfer. However it is not recommended for Big data applications.