npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

apaas-track

v1.0.22

Published

1. 修复get post 传参收集丢失问题 ### 1.0.21 1. 增加http选项 控制http请求提交内容 ``` export interface ITrackHttpOptions { trackHeaders?: boolean; trackRequesetData?: boolean trackResponseData?: boolean; // 返回false则不参与提交,返回true则参与提交,可以自行过滤,如果返回一个对象,则是可以将提交之前的数据进

Downloads

1,087

Readme

1.0.22

  1. 修复get post 传参收集丢失问题

1.0.21

  1. 增加http选项 控制http请求提交内容
export interface ITrackHttpOptions {
    trackHeaders?: boolean;
    trackRequesetData?: boolean
    trackResponseData?: boolean;
    // 返回false则不参与提交,返回true则参与提交,可以自行过滤,如果返回一个对象,则是可以将提交之前的数据进行变更。
    trackFilter?: (property: ITrackHttpProperty, item: NetworkRequestItem) => boolean | ITrackHttpProperty;
}

1.0.18

  1. 更新online事件绑定事件兼容方法,以及更改首次发送日志时间提前到2秒

1.0.17

  1. 修改online事件保存数据逻辑。整体放入logs中缓存,下次发送。

1.0.16

  1. 修改close 事件上传再下一次访问时再上传,避免数据丢失
  2. 修改iframe情况下,online数据保留,再下一次访问再上传,避免丢失

1.0.15 修复apaas-spu 在iframe中 online事件首次不主动执行问题

1.0.14 开放apaas-spu online功能

1.0.13 清除log打印

1.0.10 修复vue引用关系导致内存回收问题。

1.0.9 修复通用工具通过wx对象判断是否是小程序端的问题。

1.0.7 spu 版本默认添加client: Web

1.0.6 修复executeMain错误

1.0.3

  1. 支持web端spu 设置url。
window.getApaasSpuTrack({
    url: "https://log.xtion.net/?project=apaas_spu",
    async getWebInitParams() {
        return {
            client: "test-client",
            clientver: "test-clientver",
            project: "test-project",
            appid: "test-appid",
            accountcode: "test-accountcode",
            tenantcode: "test-tenantcode",
            mbcode: "test-mbcode",
            envname: "test-envname",
            tenantname: "test-tenantname",
            positionname: "test-positionname",
            username: "test-username",
            userinfoname: "test-userinfoname",
        };
    },
}).then((apaasSpuTrack) => {
    apaasSpuTrack.start();
});

1.0.2

  1. 统一spu,做包装,废弃apaas-mobile-spu apaas-engine-spu
    // 手机端
    // 1. 实现window.aPaaS.sendLog(log, isImmediate)方法,将日志数据接入原生日志系统
    // 2. 实现window.aPaaS.getWebInitParams(callback)方法,获取日志系统初始化通用数据
    // 开启
    window.ApaasSpuTrack.getApaasSpuTrack().then((apaasSpuTrack) => {
        apaasSpuTrack.start()
    })
    // web 端iframe容器接入
    // 1. 安装apaas-track 版本^1.0.2
    // 2. 确认public/static/apaas-track/apaas-spu/index.umd.js文件是否存在,正常已放入engine/public文件夹下。
    // 3. spu 容器层, 监听iframe onlod事件,由于同源策略,onload事件里,拿到iframe的contentDocument,添加标签<script src="./static/apaas-track/apaas-spu/index.umd.js"></script>
    // <script>
    // window.ApaasSpuTrack.getApaasSpuTrack().then((apaasSpuTrack) => {
    //     apaasSpuTrack.start()
    // })
    // </script>
    // 至contentDocument中。尽量保证优先加载。
    // 4 spu容器层需要做一下代码处理:
    import { getApaasTrack } from 'apaas-sdk/lib/Engine/init/trace'
    window.addEventListener('message', (e) => { // 记得回收注销
        const data = e?.data || {};
        if (data.type === 'getWebInitParams') {
            let commonLog = getApaasTrack().commonLog
            // 需要结合module 数据变更commonLog
            iframe?.contentWindow?.postMessage(
                        {
                            type: "receiveWebInitParams",
                            data: commonLog,
                        },
                        "*"
                    );
        }
    })

1.0.0 版本重构,拆除引擎事件,独立管理。


0.0.7

判断内容大小超过 1M,分包上传

0.0.8

添加 performance 事件,收集性能相关数据

0.0.10

添加日志通用数据中添加 url 收集 location.href 的数据

0.0.11

  1. 添加 pageview 事件,记录 hash 页面切换时候的 from, to 的 url, 切换的 entertype 类型 "onload" | "push" | "back" | "replace" | "forward"
{
    "from": "http://localhost:5173/#/center",
    "to": "http://localhost:5173/#/about",
    "entertype": "push"
}

0.0.12

  1. 添加 click 事件记录
export interface ITrackClickEventOptions {
    collectUrl?: (location: Location) => boolean; // 判断当前页面是否需要收集点击事件 默认都收集
    collectElement?: (e: MouseEvent) => boolean; // 判断触发元素是否需要收集点击事件 默认收集元素上绑定【apaas-track-click】属性
    customProperty?: Array<string>; // 元素上是否有携带数据 // 默认data-apaastrack-xxx 会将xxx的数据上传,用户可以自行添加属性。
    trackElementPath: boolean; // 是否需要提交事件元素的路径, 默认不提交
}

0.0.13

  1. 通用属性添加 appid 字段

IOS  --com.xuanwu.apaas.ios
ANDROID --com.xuanwu.apaas.android
IDE	    --com.xuanwu.apaas.ide
WEB         --com.xuanwu.apaas.web
SERVER	    --com.xuanwu.apaas.server
H5     --com.xuanwu.apaas.h5

0.0.14

  1. 修复优化获取解析httpresponse 字节数计算方法

0.0.15

  1. 修复performance.timing.connectEnd 数据错误问题
  2. 修改online事件以及click事件name问题

0.0.16

  1. 优化日志分组代码算法。
  2. 去除flycode 关于script中的记录,由于数据可能过大导致日志过大。
  3. 添加pagebegin 协议对pageinfo的记录
  4. 优化page request 等记录response数据,过大情况下转换成字符串,截取部分数据记录。

0.0.17

  1. 压缩工具接入worker. 默认的worker path为pathname/static/lzma_worker.js, 接入的客户端需要此文件复制到响应的位置

0.0.19

  1. 优化lzma服务单例

0.0.21

  1. 优化lzma兼容worker与普通模式,开启woker需要将node_modules下的lzma_worker-min.js文件放入static/ 下

0.0.22

  1. 修复bug

0.0.23

  1. lzma_work-min.js文件引入有问题,不能压缩,需要引入lzma_worker.js

0.0.24

  1. 删除console.info

0.0.25

  1. 添加logsdkver字段,记录sdk版本,以便查找bug

0.0.26

  1. 修复pagebegin 丢失protocol bug

0.0.27

  1. 处理error throw捕获详细信息,收集Error type类型 放入name