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

xml-js

Package Overview
Dependencies
Maintainers
1
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

xml-js - npm Package Compare versions

Comparing version 1.5.1 to 1.5.2

11

lib/xml2js.js

@@ -99,9 +99,6 @@ var sax = require('sax');

if (instruction.body && (instruction.name.toLowerCase() === 'xml' || options.instructionHasAttributes)) {
while (instruction.body) {
var attribute = instruction.body.match(/([\w:-]+)\s*=\s*(?:"([^"]*)"|'([^']*)'|(\w+))\s*/);
if (!attribute) {
break;
}
attributes[attribute[1]] = attribute[2];
instruction.body = instruction.body.slice(attribute[0].length); // advance the string
var attrsRegExp = /([\w:-]+)\s*=\s*(?:"([^"]*)"|'([^']*)'|(\w+))\s*/g;
var match;
while ((match = attrsRegExp.exec(instruction.body)) !== null) {
attributes[match[1]] = match[2] || match[3] || match[4];
}

@@ -108,0 +105,0 @@ }

{
"name": "xml-js",
"version": "1.5.1",
"version": "1.5.2",
"description": "A convertor between XML text and Javascript object / JSON text.",

@@ -80,12 +80,12 @@ "repository": {

"codeclimate-test-reporter": "^0.5.0",
"coveralls": "^2.13.1",
"cross-env": "^5.0.5",
"coveralls": "^3.0.0",
"cross-env": "^5.1.1",
"globify": "^2.1.0",
"istanbul": "^0.4.5",
"jasmine": "^2.8.0",
"nodemon": "^1.12.0",
"npm-run-all": "^4.1.1",
"typescript": "^2.5.2",
"nodemon": "^1.12.1",
"npm-run-all": "^4.1.2",
"typescript": "^2.6.1",
"watch": "^1.0.1"
}
}

@@ -237,3 +237,3 @@ ![XML ⇔ JS/JSON](http://nashwaan.github.io/xml-js/images/logo.svg)

Because any good library should support command line usage, this library is no difference.
Because any good library should support command line usage, this library is no different.

@@ -269,2 +269,3 @@ ## As Globally Accessible Command

Now in the command line, you can run this script by typing:
```

@@ -271,0 +272,0 @@ npm run convert // task 'scripts.convert' will be executed

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