-
-
Notifications
You must be signed in to change notification settings - Fork 19
Closed
Labels
enhancementNew feature or requestNew feature or request
Description
For example:
// node_modules/some-auth-library/package.json
{
"name": "some-auth-library",
"exports": {
"./hattip-auto-integration": "./dist/hattip.js"
}
}// node_modules/some-auth-library/hattip.ts
export default {
addHattipMiddleware,
}
function addHattipMiddleware() {
return (ctx) => {
const response = await ctx.next();
response.headers.set("Cookie", "auth-secret=...");
return response;
}
}I would even go as far as to have HatTip read the pacakge.json#exports of all dependencies to see if they contain a HatTip zero-config integration.
So that all the user has to do is to npm install some-auth-library. Zero integration code needed. Works across all JS server platforms.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request