Last 12 weeks · 0 commits
4 of 6 standards met
While not my intention when initially creating , it ended up being a drop in replacement for this module. It has a few key advantages: It's a more generalized Proxy generator. Allowing for any generator function (not just ), and allows passing any number of arguments. It implements much more of the Proxy API. Allowing things like , , setting values, and reflecting on property descriptors of the underlying object, etc. will work exactly as this module does, so the API is a drop in replacement. Proxy can be made to respond correctly to ( will always report regardless of the proxied object). Support for revocable proxies. It has a fun name. Obviously not all of those are applicable to the goal of lazy importing, but there are a few items worth porting here at a minimum.
Repository: sindresorhus/import-lazy. Description: Import a module lazily Stars: 248, Forks: 18. Primary language: JavaScript. Languages: JavaScript (92.3%), TypeScript (7.7%). License: MIT. Latest release: v4.0.0 (6y ago). Open PRs: 0, open issues: 0. Last activity: 3y ago. Community health: 85%. Top contributors: sindresorhus, bfred-it, sonicdoe, danielhusar, BendingBender, fabiospampinato, jamestalmage, rjoaopereira, Richienb.
Hi there, When I try the "Usage with bundlers" example in README with TypeScript, the following failure occurs: https://github.com/sindresorhus/import-lazy/tree/4fea4ed97eb932fa997e2d8efeef298d3aa531a7#usage-with-bundlers I think the argument should be optional, but I'm not confident: https://github.com/sindresorhus/import-lazy/blob/4fea4ed97eb932fa997e2d8efeef298d3aa531a7/index.d.ts#L22-L24 What do you think? Reproduction : : : Related to #15