Socket
Socket
Sign inDemoInstall

posthtml-parser

Package Overview
Dependencies
Maintainers
3
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

posthtml-parser - npm Package Compare versions

Comparing version 0.3.0 to 0.3.1

14

index.js

@@ -5,2 +5,3 @@ 'use strict';

var isObject = require('isobject');
var objectAssign = require('object-assign');

@@ -48,2 +49,13 @@ /**

function normalizeArributes(attrs) {
var result = {};
Object.keys(attrs).forEach(function(key) {
var obj = {};
obj[key] = attrs[key].replace(/"/g, '"');
objectAssign(result, obj);
});
return result;
}
var parser = new htmlparser.Parser({

@@ -67,3 +79,3 @@ onprocessinginstruction: parserDirective,

if (Object.keys(attrs).length) {
buf.attrs = attrs;
buf.attrs = normalizeArributes(attrs);
}

@@ -70,0 +82,0 @@

7

package.json
{
"name": "posthtml-parser",
"version": "0.3.0",
"version": "0.3.1",
"description": "Parse HTML/XML to PostHTMLTree",

@@ -28,4 +28,5 @@ "keywords": [

"dependencies": {
"htmlparser2": "^3.8.3",
"isobject": "^2.1.0"
"htmlparser2": "^3.9.2",
"isobject": "^2.1.0",
"object-assign": "^4.1.1"
},

@@ -32,0 +33,0 @@ "devDependencies": {

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