Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

metalsmith-sitemap

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

metalsmith-sitemap - npm Package Compare versions

Comparing version 0.0.4 to 0.0.5

15

lib/index.js
var fs = require('fs'),
Handlebars = require('handlebars'),
_ = require('lodash'),
toFn = require('to-function'),
url = require('url'),
defaultsDeep = _.partialRight(_.merge, function deep(value, other) {
return _.merge(value, other, deep);
}),
resolve = function(object, property) {
return _.reduce(property.split('.'), function(o, p) {
return o ? o[p] : undefined;
}, object);
};
});

@@ -19,2 +15,5 @@ module.exports = plugin;

var getUrl = toFn(options.urlProperty),
getModified = toFn(options.modifiedProperty);
var templatesDir = __dirname + '/templates';

@@ -58,4 +57,4 @@

entry = _.defaults({
loc: url.resolve(options.hostname, resolve(data, options.urlProperty)),
lastmod: resolve(data, options.modifiedProperty),
loc: url.resolve(options.hostname, getUrl(data)),
lastmod: getModified(data),
changefreq: data.sitemap.changefreq,

@@ -62,0 +61,0 @@ priority: data.sitemap.priority

{
"name": "metalsmith-sitemap",
"version": "0.0.4",
"version": "0.0.5",
"description": "A metalsmith plugin for generating a sitemap.xml file.",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

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