1.0.9 • Published 2 years ago

simplyrequire v1.0.9

Weekly downloads
-
License
ISC
Repository
-
Last release
2 years ago

simplyrequire

NPM

npm version

Require everything you could possibly need with a simple, readable one-liner, no strings attached.

BUGS (IMPORTANT)

  • This uses "sloppy" mode. Simplyrequire CANNOT be used with strict-mode applications (due to using this to find the caller's instance) and strict mode will never be planned to be compatible.
  • Works on Windows, Node.JS 12+ ONLY! I have no idea why it doesn't work anywhere else, but it does on Windows!

if you can fix any of these bugs, open an issue at our github

Why should you use it over others like requireall, which lets you require any file in a glob pattern in any folder?

  • Simple, fast local module name parsing.  |  keep your module instances as safe as possible, as quickly as possible.

  • Easy instance management.  |  just initialize with your packages.

  • Keep it true to the original require  |  execute the same functions as require, without any additions.

  • and best of all, you can still easily access module instances with this.name or even name without having to define a single variable!

USE IT!!!

require("simplyrequire")("package1", "package2");

See how simple that is? And you can still access every module as usual.

CHANGELOGS!!!

  • Removed the need for using instance keywords, now in the module.exports function, we set the instance as this.
  • Fixed stupidity ig
1.0.9

2 years ago

1.0.8-DEV

2 years ago

1.0.7-DEV

2 years ago

1.0.6-DEV

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago