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

sitemap

Package Overview
Dependencies
Maintainers
1
Versions
73
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

sitemap - npm Package Compare versions

Comparing version 3.0.0 to 3.1.0

3

CHANGELOG.md

@@ -0,1 +1,4 @@

# 3.1.0
- fixes #187, #188 typescript errors
- adds support for full precision priority #176
# 3.0.0

@@ -2,0 +5,0 @@ - Converted project to typescript

@@ -9,2 +9,3 @@ /*!

export * from './lib/errors';
export * from './lib/types';
export default sm;

@@ -21,3 +21,4 @@ "use strict";

__export(require("./lib/errors"));
__export(require("./lib/types"));
exports.default = sm;
//# sourceMappingURL=index.js.map

@@ -272,3 +272,8 @@ "use strict";

else if (this.priority !== undefined && p === 'priority') {
this.url.element(p, parseFloat(this.priority + '').toFixed(1));
if (this.conf.fullPrecisionPriority) {
this.url.element(p, this.priority + '');
}
else {
this.url.element(p, parseFloat(this.priority + '').toFixed(1));
}
}

@@ -275,0 +280,0 @@ else if (this.ampLink && p === 'ampLink') {

8

dist/lib/sitemap.d.ts

@@ -45,3 +45,3 @@ /// <reference types="node" />

*/
constructor(urls: string | Sitemap["urls"], hostname?: string, cacheTime?: number, xslUrl?: string, xmlNs?: string);
constructor(urls?: string | Sitemap["urls"], hostname?: string, cacheTime?: number, xslUrl?: string, xmlNs?: string);
/**

@@ -63,3 +63,3 @@ * Clear sitemap cache

*/
add(url: string): number;
add(url: string | SitemapItemOptions): number;
/**

@@ -69,5 +69,3 @@ * Delete url from sitemap

*/
del(url: string | {
url: string;
}): number;
del(url: string | SitemapItemOptions): number;
/**

@@ -74,0 +72,0 @@ * Create sitemap xml

@@ -64,7 +64,10 @@ /* eslint-disable camelcase, semi, space-before-function-paren, padded-blocks */

this.hostname = hostname;
// URL list for sitemap
this.urls = [];
// Make copy of object
if (urls)
if (urls) {
this.urls = Array.isArray(urls) ? Array.from(urls) : [urls];
}
else {
// URL list for sitemap
this.urls = [];
}
// sitemap cache

@@ -71,0 +74,0 @@ this.cacheResetPeriod = cacheTime || 0;

@@ -22,3 +22,3 @@ import builder from 'xmlbuilder';

export interface INewsItem {
access: 'Registration' | 'Subscription';
access?: 'Registration' | 'Subscription';
publication: {

@@ -28,7 +28,7 @@ name: string;

};
genres: string;
genres?: string;
publication_date: string;
title: string;
keywords: string;
stock_tickers: string;
keywords?: string;
stock_tickers?: string;
}

@@ -83,2 +83,3 @@ export interface ISitemapImg {

changefreq?: EnumChangefreq;
fullPrecisionPriority?: boolean;
priority?: number;

@@ -85,0 +86,0 @@ news?: INewsItem;

{
"name": "sitemap",
"version": "3.0.0",
"version": "3.1.0",
"description": "Sitemap-generating framework",

@@ -111,3 +111,2 @@ "keywords": [

"source-map": "~0.7.3",
"standard": "^12.0.1",
"stats-lite": "^2.2.0",

@@ -114,0 +113,0 @@ "typescript": "^3.4.5"

@@ -7,2 +7,8 @@ sitemap.js

Maintainers
-----------
- [@ekalinin](https://github.com/ekalinin)
- [@derduher](https://github.com/derduher)
[![Build Status](https://travis-ci.org/ekalinin/sitemap.js.svg?branch=master)](https://travis-ci.org/ekalinin/sitemap.js)

@@ -9,0 +15,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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