Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Hierarchical, declarative configuration of Promise-based, JSON-ready, XHR communication with remote APIs
Posterior Put a nice front on your backend! Posterior gives your remote APIs intuitive, Promise-based, JSON-ready JavaScript interfaces via flexible, declarative, hierarchical configurations.
Download: posterior.min.js or posterior.js
Bower: bower install posterior
NPM: npm install posterior
var GitHub = new Posterior({
url: 'https://api.github.com',
load: function() {
console.log('Requested:', this.cfg.url);
},
ESHA: {
url: '/repos/esha/{0}',
Version: {
follows: 'tags_url',
then: function(tags) {
return tags[0].name;
}
}
}
}, 'GitHub');
GitHub.ESHA.Version('posterior');
Posterior is a tool to handle encapsulation and configuration of "AJAX" calls. It takes a structured configuration and converts it into a hierarchy of functions that, when called, composes the desired request and response behaviors and returns a Promise. That Promise will resolve (or reject) when all the configured request and response handling has completed.
Apart from the basic XHR encapsulation and handling, Posterior provides a number of high level features commonly needed for interacting with remote resources. These include interpolating URLs, waiting for required dependencies to be resolved, throttling request rates, caching, following URLS in linked resources, singleton resources, automatic retry for failed requests, and more. The intent of this encapsulation is to allow client-side developers to keep implementation details of their interactions with remote servers out of their client-side logic. All translation between the data the client requests/receives and the data the server expects/returns can be hidden behind a friendly, Promise-returning function.
document
optional)FAQs
Hierarchical, declarative configuration of Promise-based, JSON-ready, XHR communication with remote APIs
The npm package posterior receives a total of 4 weekly downloads. As such, posterior popularity was classified as not popular.
We found that posterior demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.