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

zpin-templates

Package Overview
Dependencies
Maintainers
1
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

zpin-templates - npm Package Compare versions

Comparing version 0.0.11 to 0.0.12

17

dist/reactTemplates.js

@@ -164,2 +164,19 @@ 'use strict';

function generateProps(node, context) {
if (node.attribs[classAttr]) {
var name = node.attribs[classAttr];
name.trim();
name = name.split(" ");
name.map(function (v) {
v = v.trim();
if (v.toString().startsWith("__ga__")) {
v = v.toString().replace("__ga__", "");
var params = v.split("_");
var url = node.name == "a" ? node.attribs['href'] : "";
//在click捕获阶段处理埋点
// if(params.isArray()&&params.length>=3)
node.attribs["onClickCapture"] = "{()=>ZP.analysis.init_monitor_analy('" + url + "','" + params[0] + "','" + params[1] + "','" + params[2] + "')}";
}
});
}
var props = {};

@@ -166,0 +183,0 @@ _.forOwn(node.attribs, function (val, key) {

2

package.json
{
"name": "zpin-templates",
"version": "0.0.11",
"version": "0.0.12",
"description": "Light weight templates for react -> write html get valid react code",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -178,2 +178,19 @@ 'use strict';

function generateProps(node, context) {
if(node.attribs[classAttr]){
let name=node.attribs[classAttr];
name.trim();
name=name.split(" ");
name.map(function (v) {
v=v.trim();
if(v.toString().startsWith("__ga__")){
v=v.toString().replace("__ga__","");
let params=v.split("_");
let url=node.name=="a"?node.attribs['href']:"";
//在click捕获阶段处理埋点
// if(params.isArray()&&params.length>=3)
node.attribs["onClickCapture"]="{()=>ZP.analysis.init_monitor_analy('"+url+"','"+params[0]+"','"+params[1]+"','"+params[2]+"')}";
}
})
}
const props = {};

@@ -180,0 +197,0 @@ _.forOwn(node.attribs, (val, key) => {

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