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

gulp-parser-inline

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

gulp-parser-inline - npm Package Compare versions

Comparing version 1.6.0 to 1.6.1

7

CHANGELOG.md

@@ -0,1 +1,8 @@

## [1.6.1](https://github.com/searchfe/gulp-parser-inline/compare/v1.6.0...v1.6.1) (2019-11-06)
### Bug Fixes
* remove fast-json ([447ca53](https://github.com/searchfe/gulp-parser-inline/commit/447ca535ef31d281a274724bc475e9e8a1220a2f))
# [1.6.0](https://github.com/searchfe/gulp-parser-inline/compare/v1.5.0...v1.6.0) (2019-11-04)

@@ -2,0 +9,0 @@

2

dist/parseCss.js

@@ -71,3 +71,2 @@ "use strict";

function parseCssContent(content, options, file) {
console.time('parseCssContent');
debug('parse content', file.path);

@@ -122,5 +121,4 @@ /* eslint-disable */

console.log('filePath', file.path);
console.timeEnd('parseCssContent');
return content;
}
exports.parseCssContent = parseCssContent;

@@ -60,3 +60,2 @@ "use strict";

function parseJSContent(content, options, file) {
console.time('parseJSContent');
debug('parse content', file.path);

@@ -117,5 +116,4 @@ /* eslint-disable */

console.log('parseJSContent filepath: ', file.path);
console.timeEnd('parseJSContent');
return content;
}
exports.parseJSContent = parseJSContent;

@@ -12,3 +12,2 @@ "use strict";

function parseTpl(file, options) {
console.time('parseTpl');
debug('input file', file.path);

@@ -30,3 +29,2 @@ var content = '';

console.log('parseTpl filePath', file.path);
console.timeEnd('parseTpl');
return content;

@@ -33,0 +31,0 @@ }

@@ -7,8 +7,2 @@ "use strict";

var path = require("path");
var parseJson = require("fast-json-parse");
var fastJson = require("fast-json-stringify");
var stringify = fastJson({
title: 'Example Schema',
type: 'object'
});
var debug = debug_1.default('inline:utils');

@@ -27,12 +21,9 @@ function isInline(url) {

function getFileDataFromResourceMap(key, sourceMapPath) {
console.time('read source');
key = path.relative(process.cwd(), key);
if (fs.existsSync(sourceMapPath)) {
var fileContent = fs.readFileSync(sourceMapPath, 'utf-8');
var fileObj = parseJson(fileContent || '{}');
var fileObj = JSON.parse(fileContent || '{}');
debug('getFile: ' + key + '; Data: ', fileObj[key] ? fileObj[key] : 'null');
console.timeEnd('read source');
return fileObj[key] ? fileObj[key] : {};
}
console.timeEnd('read source');
return {};

@@ -42,6 +33,5 @@ }

function writeMap(key, value, sourceMapPath) {
console.time('writeMap');
var obj = {};
if (fs.existsSync(sourceMapPath)) {
obj = parseJson(fs.readFileSync(sourceMapPath).toString());
obj = JSON.parse(fs.readFileSync(sourceMapPath).toString());
}

@@ -54,4 +44,3 @@ // if (value.md5) {

debug('writeFile: ' + key + '; data: ', obj[key].output);
fs.writeFileSync(sourceMapPath, stringify(obj), 'utf-8');
console.timeEnd('writeMap');
fs.writeFileSync(sourceMapPath, JSON.stringify(obj), 'utf-8');
}

@@ -58,0 +47,0 @@ exports.writeMap = writeMap;

{
"name": "gulp-parser-inline",
"version": "1.6.0",
"version": "1.6.1",
"discription": "gulp-parser-inline",

@@ -81,4 +81,2 @@ "scripts": {

"escape-html": "^1.0.3",
"fast-json-parse": "^1.0.3",
"fast-json-stringify": "^1.15.6",
"gulp-util": "^3.0.8",

@@ -85,0 +83,0 @@ "html-minifier": "^4.0.0",

Sorry, the diff of this file is too big to display

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