{"id":15680701,"url":"https://github.com/lucsoft/esbuild_serve","last_synced_at":"2026-03-08T05:31:32.028Z","repository":{"id":41906033,"uuid":"470307022","full_name":"lucsoft/esbuild_serve","owner":"lucsoft","description":"A Deno Web bundler.","archived":false,"fork":false,"pushed_at":"2026-02-07T00:28:12.000Z","size":87,"stargazers_count":14,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-02-07T11:29:47.642Z","etag":null,"topics":["bundler","deno","esbuild","webdev"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/lucsoft.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2022-03-15T19:39:28.000Z","updated_at":"2026-02-07T00:28:16.000Z","dependencies_parsed_at":"2023-02-10T05:31:30.448Z","dependency_job_id":"33451b7f-4345-4011-9727-c4749f8ce086","html_url":"https://github.com/lucsoft/esbuild_serve","commit_stats":{"total_commits":83,"total_committers":4,"mean_commits":20.75,"dds":0.3373493975903614,"last_synced_commit":"232488f4344b0d938f0787ef881a98fed0b8608d"},"previous_names":[],"tags_count":29,"template":false,"template_full_name":null,"purl":"pkg:github/lucsoft/esbuild_serve","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lucsoft%2Fesbuild_serve","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lucsoft%2Fesbuild_serve/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lucsoft%2Fesbuild_serve/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lucsoft%2Fesbuild_serve/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lucsoft","download_url":"https://codeload.github.com/lucsoft/esbuild_serve/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lucsoft%2Fesbuild_serve/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30246724,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-08T00:58:18.660Z","status":"online","status_checked_at":"2026-03-08T02:00:06.215Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["bundler","deno","esbuild","webdev"],"created_at":"2024-10-03T16:43:58.074Z","updated_at":"2026-03-08T05:31:32.005Z","avatar_url":"https://github.com/lucsoft.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# esbuild_serve\n\nLive Reload. Persistent HTTP Import Resolution. Templates. Dev Server. Polyfills. A Deno Web bundler.\n\n## Get denoing 🦕🔨\n\n### Pages\n\nPages are a simple way to get going fast.\n\n```ts\nimport { serve } from \"https://deno.land/x/esbuild_serve/mod.ts\";\n\nserve({\n    port: 8100,\n    pages: {\n        \"index\": \"demo/index.ts\"\n    }\n});\n```\nThis will automatically create a HTML Template for you. If you want to have a custom one just place it in `templates/demo/index.html`.\n\n### Custom Assets\n\nAdding plain assets to your build folder goes like this\n\n```ts\nimport { serve } from \"https://deno.land/x/esbuild_serve/mod.ts\";\n\nserve({\n    pages: { \"index\": \"index.ts\" },\n    assets: {\n        \"favicon.ico\": \"./static/favicon.ico\"\n    }\n})\n```\n\n### Custom Templates\n\nIf you have have a setup like this: `serve({ pages: { \"/document/page/index\": \"index.ts\" } })`\n\n```\nResoultion will be like this:\n/templates/document/page/index.html\n\nIf this fails, then:\n/templates/index.html\n\nFallback:\nAutogenerated via filename\n```\n\nYou can place an html file at these locations.\n\n## Releasing your bundle\n\nAs simple as starting deno with the args `deno run -A serve.ts build`\n\n## Spicing your Builds\n\n1. Define globalThis variables\n\n    ```ts\n    serve({\n        globals: {\n            \"BUID_TIMESTAMP\": new Date().getTime(),\n            \"GIT_BRANCH\": getGitBranch(),\n            \"COPYRIGHT_YEAR\": new Date().getFullYear()\n        }\n    })\n    ```\n\n2. Adding Polyfills\n\n    ```ts\n    serve({\n        polyfills: [\n            \"https://unpkg.com/construct-style-sheets-polyfill\",\n            \"https://unpkg.com/compression-streams-polyfill\"\n        ]\n    })\n    ```\n\n## Note\n\n- Since v1.2.0 live reload is fully done by esbuild (since 0.17) and the dev server is based opon esbuild (with custom routing added on top)\n\n## Internal Plugins\n\nOnly want templates or http imports? just import them!\n\n```ts\nimport { build } from \"https://deno.land/x/esbuild/mod.js\";\nimport { autoTemplates } from \"https://deno.land/x/esbuild_serve/features/templates.ts\";\nimport { httpImports } from \"https://deno.land/x/esbuild_serve/features/httpImports.ts\";\nbuild({\n    entryPoints: {\n        app: \"app.ts\"\n    },\n    plugins: [\n        autoTemplates({\n            pages: {\n                \"app\": \"./app.ts\"\n            }\n        }),\n        httpImports({ sideEffects: false }),\n    ]\n})\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flucsoft%2Fesbuild_serve","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flucsoft%2Fesbuild_serve","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flucsoft%2Fesbuild_serve/lists"}