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

node-jsml

v1.0.10

Published

JSON Markup Language Compiler

Downloads

3

Readme

JSML

JSML (JSON Markup Language) is an investigation into the effectiveness of creating webpages in JSON.

npm version license downloads

Installation

As JSML is on npm, you can install it easily with the command npm install -g node-jsml.

On some systems, superuser access might be required.

Use

Through the Terminal

To compile a JSML (a .jsml file) into an HTML file, run jsml [filename].

If you want to output to stdout, use -c in front of the file, and -O to directly specify the output path.

Through Your Program

To include JSML, use jsml = require('node-jsml');

To compile a JSML file to HTML, use the following code


var jsml = require('node-jsml');

myJSML = [
	{
		t:"p",
		T:"this works!"
	}
];

output = jsml.parse(myJSML);

parse has an optional parameter, eval. If true, then myJSML (f.e. in this example) will be run though eval. This is helpful when reading .jsml files which don't have " around every tag.

Syntax and Language

All the rules and tricks can be found in LANG.md

Inspiration

When using APIs, one lets out a groan when if they see the API outputs data in XML format. JSON is expected, nowadays, when using an API. Nobody has this problem when writing HTML, however. Perhaps this is because writing a webpage in XML format is better than writing it in JSON. But, until now, there has been no way to tell. And thus, JSML was born.

This isn't meant to overtake web design as we know it. It's more of a proof of concept. However, JavaScript code can actually be executed within the JSML file, which is kind of neat. One could make counters, dynamic variables, etc. The possibilities are unexplored and endless!

Contributing

If you have something very major to contribute, submit an issue first. Otherwise, for any small fixes, feel free to send a pull request.

If you'd like to find issues to work on, check TODO.md.

Note: The logo (svg source file) uses the font monofur.