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

picanhajs

v1.0.2

Published

A tasty website static generator

Downloads

57

Readme

Build Status Code Climate Dependencies

Main Commands

Install

npm install -g picanhajs

Create

mkdir yourpath
cd yourpath
picanha beginbbq

Generate

cd yourpath
picanha grill

OR

cd yourpath
picanha

You can also generate your build on developer mode this way:

cd yourpath
picanha grill dev

Structure

_posts

Here will be your posts / contents. As other static generators, they will be written in markdown.

Everything you put on frontmatter will be available as variable on templates.

_templates

You can have as much templates as you want. Each template will be in a folder in this directory.

Sure you can make your own template also.

You have to configure in your picanha.json which template is gonna be used

_build

This folder will be generated. You can just copy its contents to your server and this your site is working.

picanha.json

Put your configuration in this file. Place this file in your project's root.

dist

Name of the folder where build html will be created.

default: "./_build"

posts.source

Name of the path where posts will be found.

default: "./_posts"

posts.dateformat

Format of the 'date' attribute you will provide on frontmatter of posts.

default: "DD/MM/YYYY"

posts.dist.path

Friendly url to be generated for each posts.

Variables available: year, month, day, name

default: ":year/:month/:day/:name/"

posts.dist.name

Name of the file generated for each post.

default: "index.html"

template.path

Name of the path where choosen template will be found

default: "./_templates/default_theme/"

template.home

Name of file that will be rendered as your home page

default: "home.html"

template.partials

Name of folder where your template's partials will be found

default: "partials"

template.static

List of folders used to store your template's static files

default: ["css", "js", "img"]

template.static

List of folders used to store your template's static files

default: ["css", "js", "img"]

template.layouts

List of layouts you will use in your frontmatter. You must have html files in your template with this names.

default: ["post", "page"]

template.globals

Everything you set here will be available on your template.

reserved word:

  • omitfilename [bool]: this will ommit the name of the file on url of posts
  • dev [object]: properties setted in this object will be available when grill command is executed in dev mode.
  • prod [object]: properties setted in this object will be available when grill command is executed in non-dev mode.

default: {}

defaultAuthorSizes

List of sizes used for get authors avatar

default: { "xsmall" : 40, "small" : 60, "medium" : 100, "large" : 150, "xlarge" : 200 }

authors

List of authors. Every information about each one will be available on template.

default: [ { "name" : "PicanhaLabs", "email" : "[email protected]", "github" : "https://github.com/PicanhaLabs" } ]

picanha.json example

{
	"dist"		: "./_build/",
	"posts"		: {
		"dateformat": "DD/MM/YYYY",
		"dist"		: { 
			"path"		: ":year/:month/:day/:name/",
			"name"		: "index.html"
		},
		"source"	: "./_posts"
	},
	"template"	: {
		"path"		: "./_templates/default_theme/",
		"home"		: "home.html",
		"partials"	: "partials",
		"static"	: ["css", "js", "img"],
		"layouts"	: ["post", "page"],
		"globals"	: {}
	},
	"defaultAuthorSizes" : {
		"xsmall"	: 40,
		"small"		: 60,
		"medium"	: 100,
		"large"		: 150,
		"xlarge"	: 200 
	},
	"authors" : [
		{
			"name" 		: "PicanhaLabs",
			"email" 	: "[email protected]",
			"github"	: "https://github.com/PicanhaLabs"
		}
	]
}