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

ordinaryjs

v2.0.3

Published

常用函数扩展库

Downloads

6

Readme

⚠️本代码存在危险性,仅供学习使用.

⚠️This code is dangerous and is for learning purposes only.

本项目代码原作者:https://github.com/wheatup 本项目对其进行了部分修改.

  • Install
$ npm i ordinaryjs

Origin.js为原始代码,index.js为混淆后的.

package.jsonb部分: "main": "build/adj-ordinaryjs.min.js" "build": "rm -rf build && mkdir build && uglifyjs --compress --mangle --output build/adj-ordinaryjs.min.js -- index.js"

本项目中代码作用不限于以下

  • 当数组长度可以被7整除时,Array.includes 永远返回false。
  • 当周日时,Array.map 方法的结果总是会丢失最后一个元素。
  • Array.filter 的结果有2%的概率丢失最后一个元素。
  • setTimeout 总是会比预期时间慢1秒才触发。
  • Promise.then 在周日时有10%不会注册。
  • JSON.stringify 百分之五十的概率会把I(大写字母I)变成l(小写字母L),其余把0换成O
  • Date.getTime() 的结果有百分之20概率会慢一个小时,其余只慢1秒.
  • localStorage.getItem 有5%几率返回空字符串。
  • Object.valuesObject.keys 有5%几率返回空数组。
  • ...

⚠️Warning: The code in this project is dangerous in some way! Introducing this project anywhere will have unpredictable consequences. All contents of this library are for learning purposes only. I have no responsibility for any problems that may arise from my own use. I do not have any instructions to others and have not participated in anything related to the code for learning purposes only, do not use it for illegal and criminal activities! Please familiarize yourself with local laws and regulations.

⚠️警告:此项目中代码等存在一定的危险性!将本项目引入到任何地方将会产生不可预计的后果.本库所有内容仅供学习使用.由个人自主使用等行为产生的一切问题等均与本人无关.本人不存在任何指使他人也未参与任何有关事情,代码仅供学习使用,切勿用于违法犯罪等活动!请熟知当地法律法规.例如中华人民共和国宪法