{"library":"rollup-endpoint","title":"rollup-endpoint","description":"Serve a Rollup-bundled JavaScript file directly from an Express.js endpoint with minimal configuration. Current stable version is 0.2.2. It builds bundles on the fly during development and enables caching with gzip in production via the NODE_ENV environment variable. Differentiators include zero build step integration, automatic caching, and support for all Rollup options including plugins and generate options. Ideal for rapid prototyping or simple SPAs without a separate build system.","language":"javascript","status":"active","last_verified":"Mon Apr 27","install":{"commands":["npm install rollup-endpoint"],"cli":null},"imports":["import rollupEndpoint from 'rollup-endpoint'","import rollupEndpoint from 'rollup-endpoint'; const { serve } = rollupEndpoint;","const rollupEndpoint = require('rollup-endpoint');"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"// server.js\nconst rollupEndpoint = require('rollup-endpoint');\nconst express = require('express');\nconst app = express();\n\napp.get('/bundle.js', rollupEndpoint.serve({\n  entry: require('path').join(__dirname, 'client', 'main.js'),\n  plugins: process.env.NODE_ENV === 'production'\n    ? [\n        require('rollup-plugin-buble')(),\n        require('rollup-plugin-uglify')()\n      ]\n    : []\n}));\n\napp.listen(3000, () => console.log('Server running on port 3000'));\n","lang":"javascript","description":"Creates an Express server that serves a Rollup-bundled JavaScript file from client/main.js, with production plugins for transpilation and minification.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}