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

@wemnyelezxnpm/nemo-accusamus-magnam

v1.0.0

Published

A simple cache system for a single user request, built on the same concepts of [data loader](https://github.com/facebook/dataloader).

Downloads

2

Maintainers

mol86237mol86237

Keywords

bundlingdiffpropertyArray.prototype.findLastIndexbabel-corextermdebugpoint-freemovedefaulttoobjectclassesinternaldescriptionReflect.getPrototypeOfdeleteframerbytehelpersutilitiesasyncES2023gradients css3colourshamstablebyteOffsetString.prototype.matchAllperformanceshebangdataviewparentsetPrototypeOfstreamsfetchformatspechookformstreams2watchcachehttpseast-asian-widthmobilesuperagentprotobufweaksetbindmakefstypedarraytoArraypropertiesstringmkdirpObjectreadvaluesSetkarmavaluewritableincludesposebootstrap lessArray.prototype.flatMapmacosrecursivetraversepasswordobjnested cssObject.isprivate dataObject.fromEntriesassertionwalkingefficient6to5chineseECMAScript 6reduxclass-validatorxdg-openperformantjses-abstractdotenvreact-testing-librarynpmECMAScript 2020moduleurltypanionflattencss lessUint16Arrayrandomprogressvariables in cssequalitycryptocopyArrayBuffer#sliceworkerjsonpathmergeclassnamescore-jshooksless compilerreduceSymbolpackage.jsonArray.prototype.flattenhigher-ordersignalsURLindicatortypeoffromfast-deep-clonewidthyamllesses-shim APIES2015errortoSortedlanguagetimeECMAScript 2017phoneauthenticationspinnersarrayshttpgetintrinsiccheckeditortc39variablesargumentstatusasciimatchlistenersopenseslint-plugin-0ECMAScript 2015yupdropoptimistloggertelephonemruinput__proto___.extendprototypeidlemimees2017ESnextelectrondeepcloneinstallersigintregular expressionsmime-dbreal-timemochapackageeslintconfigvestframeworkquerystringflatMapjson-schema-validationexpressesintrinsicObject.assignfastcloneopen[[Prototype]]ES

Readme

@wemnyelezxnpm/nemo-accusamus-magnam

A simple cache system for a single user request, built on the same concepts of data loader.

Install

npm i @wemnyelezxnpm/nemo-accusamus-magnam

Usage

const { Factory } = require('.')
const factory = new Factory()

factory.add('fetchSomething', {
  // cache by default, set to false to just do batching
  cache: true
}, async (queries, context) => {
  console.log(queries)
  // [ 42, 24 ]

  console.log(context)
  // { some: 'data' }

  return queries.map((k) => {
    return { k }
  })
})

async function run () {
  const context = {
    some: 'data'
  }
  const cache = factory.create(context)

  const p1 = cache.fetchSomething(42)
  const p2 = cache.fetchSomething(24)

  const res = await Promise.all([p1, p2])

  console.log(res)
  // [
  //   { k: 42 },
  //   { k: 24 }
  // ]
}

run().catch(console.log)

If the query parameter is an object, its cache key will be generated using safe-stable-stringify.

License

MIT