{"id":20438310,"url":"https://github.com/seebigs/bundl","last_synced_at":"2025-04-12T22:34:27.586Z","repository":{"id":57191515,"uuid":"49017940","full_name":"seebigs/bundl","owner":"seebigs","description":"A reinvented build tool","archived":false,"fork":false,"pushed_at":"2018-09-01T00:41:32.000Z","size":106,"stargazers_count":5,"open_issues_count":1,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-01T13:38:01.954Z","etag":null,"topics":["build-tools","bundlers","dev-servers","frontend-bundles","on-demand"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/seebigs.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2016-01-04T19:22:49.000Z","updated_at":"2018-10-26T19:15:12.000Z","dependencies_parsed_at":"2022-09-15T22:30:50.689Z","dependency_job_id":null,"html_url":"https://github.com/seebigs/bundl","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seebigs%2Fbundl","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seebigs%2Fbundl/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seebigs%2Fbundl/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/seebigs%2Fbundl/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/seebigs","download_url":"https://codeload.github.com/seebigs/bundl/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248543853,"owners_count":21121838,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["build-tools","bundlers","dev-servers","frontend-bundles","on-demand"],"created_at":"2024-11-15T09:10:22.729Z","updated_at":"2025-04-12T22:34:27.563Z","avatar_url":"https://github.com/seebigs.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Bundl\n\u003e Become a master of bundles\n* [API Documentation](docs/API.md)\n* [Popular Plugins](docs/PLUGINS.md)\n* [Examples](docs/EXAMPLES.md)\n\n## What Is Bundl?\nBundl builds and packages files for your frontend codebase. It switches the paradigm of when resources are built vs when they are needed ([Bundl On-Demand](docs/BUILD_ON_DEMAND.md)). Use it as a task manager or use it to package your source code with additional resources (like styles and images) into a JavaScript bundle that can be served to your web browser.\n\n## Why Use Bundl?\n* Build resoucres only when requested by your browser (and only if they've changed) ([Example](docs/BUILD_ON_DEMAND.md))\n* Easily concat, require, and wrap all of your various resources to generate the bundle you really need ([Example](docs/EXAMPLES.md#bundles-for-browsers))\n* Run other tasks like linting, file system operations, etc. ([Example](docs/EXAMPLES.md#server-side-operations))\n* Write next generation ES6 JavaScript today with a transpiler plugin ([Example](https://github.com/seebigs/bundl-pack-babel))\n\n---\n## Get Started\n\n### Install\n```\n$ cd ~/myProject\n$ npm install bundl --save-dev\n```\n\n### Create Your Build Script\nMake a new file at `~/myProject/bundl.js`\n```js\nvar Bundl = require('bundl');\n\n// Plugins\nvar pack = require('bundl-pack');\nvar minify = require('bundl-minify');\nvar write = require('bundl-write');\n\n// Configure\nvar bundlOptions = {\n    outputDir: 'dist/javascripts',\n    clean: true\n};\nvar targets = {\n    'my_project_bundle.js': 'src/entry.js'\n};\n\n// Setup a build pipeline\nvar myProjectBundl = new Bundl(targets, bundlOptions)\n    .then(pack())\n    .thenif(Bundl.cliArgs.min, minify())\n    .then(write());\n\n// Start the build\nmyProjectBundl.go();\n```\n\n### Run Your Script\n```\n$ cd ~/myProject\n$ node bundl --min\n```\n\n### Run via NPM (optional)\nAdd scripts to your `package.json`\n```json\n{\n  \"name\": \"myProject\",\n  \"version\": \"0.0.1\",\n  \"dependencies\": {\n    \"bundl\": \"^1.0.0\"\n  },\n  \"scripts\": {\n    \"build\": \"node bundl.js\"\n  }\n}\n```\n```\n$ npm run build\n```\n\n---\n## How to Use\n* [Live Developing](docs/EXAMPLES.md#live-developing)\n* [Bundles for Browsers](docs/EXAMPLES.md#bundles-for-browsers)\n* [Server-Side Operations](docs/EXAMPLES.md#server-side-operations)\n* [Task Runner](docs/TASK_RUNNER.md)\n* [Specifying Targets](docs/TARGETS.md)\n\n---\n## Build Resources Live On-Demand!\n\nWhen you make a change to one source file, you shouldn't have to switch back to command line to run a task before you can see your changes live in a browser. You also shouldn't need to wait for **every** bundle to rebuild if you only want to see one or two of them. Use Bundl's dev server instead...\n```js\n// Setup a build pipeline\nvar myProjectBundl = new Bundl(targets, bundlOptions)\n    .then(pack())\n    .then(write());\n\n// Start live dev mode\nmyProjectBundl.webserver();\n```\nNow, open a browser to `http://localhost:5555`\n\nHTTP Requests for a bundled resource will check to see if any of the source files within this bundle have changed since last request. If so, the webserver will rebuild the requested bundle before sending it back to the browser.\n\nLearn how to [configure a devserver for your project](docs/BUILD_ON_DEMAND.md)\n\n---\n## Debugging\nAdd `--verbose` as a command line option to print more info about what's happening\n```\n$ node bundl --verbose\n```\nAdd `.debug()` to your build chain to print which src files will be bundled into which dest files\n```\nnew Bundl(targets, bundlOptions).debug();\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseebigs%2Fbundl","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fseebigs%2Fbundl","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseebigs%2Fbundl/lists"}