all-properties-lazy
TypeScript icon, indicating that this package has built-in type declarations

0.1.0Β β€’Β PublicΒ β€’Β Published

All Properties Lazy

Evalutes the properties of an object, including functions, Promises, and their combination. 😴

πŸ‘ͺ All Contributors: 1 🀝 Code of Conduct: Kept πŸ§ͺ Coverage πŸ“ License: MIT πŸ“¦ npm version πŸ’ͺ TypeScript: Strict

Usage

npm i all-properties-lazy
import { allPropertiesLazy } from "all-properties-lazy";

await allPropertiesLazy({
	immediate: "immediate",
	lazy: () => "lazy",
	lazyAsync: async () => {
		await Promise.resolve();
		return "lazy async";
	},
	promise: Promise.resolve("promise"),
});

Retrieves all properties of an object, factoring in lazy properties. Properties can be:

  • Immediate: a direct value
  • Lazy: a function for a value
  • Lazy and asynchronous: a function that returns a Promise
  • Promise: a direct Promise

Development

See .github/CONTRIBUTING.md, then .github/DEVELOPMENT.md. Thanks! πŸ’–

Contributors

Josh Goldberg ✨
Josh Goldberg ✨

πŸ’» πŸ–‹ πŸ“– πŸ€” πŸš‡ 🚧 πŸ“† πŸ”§

πŸ’ This package was templated with create-typescript-app using the Bingo engine.

Readme

Keywords

none

Package Sidebar

Install

npm i all-properties-lazy

Weekly Downloads

5,496

Version

0.1.0

License

MIT

Unpacked Size

8.48 kB

Total Files

9

Last publish

Collaborators

  • joshuakgoldberg