Latest version | 1.13.2.0 |
---|---|
Minimum Core | 0.6.5 |
Compatible Core | 12 |
Last updated | 1 month ago |
Created | 4 years ago |
Authors | |
Languages |
English Español Polski Português (Brasil) Português (Portugal) 日本語 |
Systems | All systems |
Project source | Project URL |
Report bugs | Bug tracker URL |
Library for Foundry VTT which provides package developers with a simple way to modify core Foundry VTT code, while reducing the likelihood of conflict with other packages and making troubleshooting easier.
The libWrapper library is intended to be used as a replacement for traditional monkey-patching methods, to make interoperability and troubleshooting easier.
It provides a standardized API, improving consistency and compatibility while reducing the likelihood of mistakes.
Its wrapping mechanisms attempt to detect and prevent conflicts between different packages. When conflicts cannot be prevented, libWrapper aids troubleshooting by notifying the game master of what went wrong, and which packages are responsible.
Traditional monkey-patching | libWrapper | |
---|---|---|
Conflict troubleshooting | Requires waiting until something goes wrong. User is responsible for figuring out if an error is caused by a conflict, and which package(s) caused it. |
Able to detect most conflicts and warn the user, in many cases automatically upon game launch. |
Error Detection | None by default. | When any error occurs, libWrapper will detect which package(s) caused it (if any), and tell the user. |
API | None. Each developer is on their own. |
Provides a standard API enforcing best-practices with included error-checking. |
Wrapper execution order | Package execution order, i.e. random. | Customizable. Developers can request to run first or last, if their module requires it. Game masters can troubleshoot conflicts by prioritising or deprioritising packages. |
Edge cases | Each developer must understand the intricacies of Javascript. | Handled automatically and transparently. |
Note: Images may be out-of-date.
See the project Github page for usage and documentation.
To install this package, open your Foundry Setup screen and navigate to your Module tab and click the Install Module button.
From there, you can either search for the package unique name: lib-wrapper or copy its manifest URL:
And paste it to the input box at the bottom of your window.
You can install this package directly to your Forge account.
Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information.
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Advertisement cookies are used to deliver visitors with customized advertisements based on the pages they visited before and analyze the effectiveness of the ad campaign.
This is such a cool library module! The most amazing part of it is the inter-module compatibility it enables with a simple and resilient way to modify core methods. Thank you for making and maintaining this ❤️
This is basically a necessity at this point. There is just no way around this module. Without it, the module ecosystem wouldn’t be at the point where it is right now. It makes it so much easier to adjust core functionality while playing nice with other modules.
Regular users probably don’t need to install this explicitly, but I recommend using it as a dependency to any fellow module developer who wants to adjust core functionality!
Thank you for maintaining this!