{"id":18033814,"url":"https://github.com/rbren/bb-asset-manager","last_synced_at":"2025-04-04T22:26:20.428Z","repository":{"id":41218974,"uuid":"43403879","full_name":"rbren/bb-asset-manager","owner":"rbren","description":null,"archived":false,"fork":false,"pushed_at":"2016-06-09T16:47:46.000Z","size":26,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-10T07:15:26.151Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/rbren.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":"2015-09-30T01:13:22.000Z","updated_at":"2016-03-12T17:26:29.000Z","dependencies_parsed_at":"2022-09-14T21:50:37.379Z","dependency_job_id":null,"html_url":"https://github.com/rbren/bb-asset-manager","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/rbren%2Fbb-asset-manager","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rbren%2Fbb-asset-manager/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rbren%2Fbb-asset-manager/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rbren%2Fbb-asset-manager/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rbren","download_url":"https://codeload.github.com/rbren/bb-asset-manager/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247257599,"owners_count":20909512,"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":[],"created_at":"2024-10-30T11:08:40.449Z","updated_at":"2025-04-04T22:26:20.409Z","avatar_url":"https://github.com/rbren.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# bb-asset-manager\nYet another asset manager for NodeJS.\n\nThis package allows you to declare a directory that will be served statically on your webserver.\nYou can then package files in that directory together into concatenated and minified assets\nwhich can be easily included in your HTML. You can also easily switch between using raw and minified\nassets e.g. for easier debugging in development.\n\n## Installation\n```bash\nnpm install --save bb-asset-manager\n```\n\n## Basic Usage\n```js\n  var AssetMan = require('bb-asset-manager');\n  var assetMan = new AssetMan({\n    staticDirectory: __dirname + '/static', // Where your static assets live\n    outputDirectory: '/minified',           // Relative to staticDirectory\n  });\n  assetMan.addAsset('bootstrap', {\n    js:  ['bower_components/bootstrap/bootstrap.js'],\n    css: ['bower_components/bootstrap/bootstrap.css'],\n  });\n\n  assetMan.addAsset('home', {\n    css: ['css/home.css'],\n    dependencies: ['bootstrap'],\n  })\n  \n  assetMan.compileSync();\n  \n  console.log(assetMan.renderAsset('home'))\n```\n\nWill output\n\n```html\n\u003clink rel=\"stylesheet\" type=\"text/css\" href=\"/minified/css/home.css\"\u003e\n\u003cscript type=\"text/javascript\" src=\"/minified/js/home.js\"\u003e\u003c/script\u003e\n```\n\n## Advanced Usage\nSee [Advanced Usage](AdvancedUsage.md) for details on controlling minification,\nconcatenation, and file ordering.\n\n\n## Contributions\nContributions are welcome! I'll try to respond to PRs within 24 hours.\n\n## TODO\n* Add a build process for e.g. ES6 and CoffeScript transpiling\n* Expose Express middleware for auto-recompiling in development\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frbren%2Fbb-asset-manager","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frbren%2Fbb-asset-manager","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frbren%2Fbb-asset-manager/lists"}