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

xml-formatter

Package Overview
Dependencies
Maintainers
1
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

xml-formatter - npm Package Compare versions

Comparing version 2.3.1 to 2.4.0

5

dist/browser/xml-formatter.js

@@ -268,2 +268,3 @@ require=(function(){function r(e,n,t){function o(i,f){if(!n[i]){if(!e[i]){var c="function"==typeof require&&require;if(!f&&c)return c(i,!0);if(u)return u(i,!0);var a=new Error("Cannot find module '"+i+"'");throw a.code="MODULE_NOT_FOUND",a}var p=n[i]={exports:{}};e[i][0].call(p.exports,function(r){var n=e[i][1][r];return o(n||r)},p,p.exports,r,e,n,t)}return n[i].exports}for(var u="function"==typeof require&&require,i=0;i<t.length;i++)o(t[i]);return o}return r})()({1:[function(require,module,exports){

function newLine(state) {
if (!state.options.indentation && !state.options.lineSeparator) return;
state.content += state.options.lineSeparator;

@@ -409,5 +410,5 @@ let i;

function format(xml, options = {}) {
options.indentation = options.indentation || ' ';
options.indentation = 'indentation' in options ? options.indentation : ' ';
options.collapseContent = options.collapseContent === true;
options.lineSeparator = options.lineSeparator || '\r\n';
options.lineSeparator = 'lineSeparator' in options ? options.lineSeparator : '\r\n';
options.whiteSpaceAtEndOfSelfclosingTag = !!options.whiteSpaceAtEndOfSelfclosingTag;

@@ -414,0 +415,0 @@

@@ -22,2 +22,3 @@ /**

function newLine(state) {
if (!state.options.indentation && !state.options.lineSeparator) return;
state.content += state.options.lineSeparator;

@@ -163,5 +164,5 @@ let i;

function format(xml, options = {}) {
options.indentation = options.indentation || ' ';
options.indentation = 'indentation' in options ? options.indentation : ' ';
options.collapseContent = options.collapseContent === true;
options.lineSeparator = options.lineSeparator || '\r\n';
options.lineSeparator = 'lineSeparator' in options ? options.lineSeparator : '\r\n';
options.whiteSpaceAtEndOfSelfclosingTag = !!options.whiteSpaceAtEndOfSelfclosingTag;

@@ -168,0 +169,0 @@

2

package.json
{
"name": "xml-formatter",
"version": "2.3.1",
"version": "2.4.0",
"repository": "github:chrisbottin/xml-formatter",

@@ -5,0 +5,0 @@ "bugs": {

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