Socket
Socket
Sign inDemoInstall

metalsmith-aliases

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

metalsmith-aliases

Create aliases for your posts and redirect from them if preferable


Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

metalsmith-aliases

Create aliases for your posts and redirect from them if preferable.

Installation

npm install --save metalsmith-aliases

Usage

This plugin depends on having an property called permalink, so in order for it to work we need to either add that ourselves or use the permalinks plugin. This needs to happen before the alias plugin.

Javascript API

var Metalsmith = require('metalsmith');
var aliases = require('metalsmith-aliases');
var permalinks = require('metalsmith-permalinks');

Metalsmith()
  .use(permalinks())
  .use(aliases());

Posts

Add your aliases in the form of an array in your posts:

---
title: Reactive extensions in Javascript
aliases: [2016/01/14/reactive-extensions-in-javascript]
---
---
title: Metalsmith aliases
aliases: [2016/03/15/metalsmith-aliases, metalsmith-using-aliases]
---

Options

Redirect

If the alias should redirect to the given post. Defaults to false.

Keywords

FAQs

Package last updated on 15 Mar 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc