{"id":17941131,"url":"https://github.com/chuhoman/vue-demi-component-template","last_synced_at":"2025-03-24T12:30:34.791Z","repository":{"id":119204150,"uuid":"472046357","full_name":"ChuHoMan/vue-demi-component-template","owner":"ChuHoMan","description":"SFC template of vue-demi project, can dev \u0026 test \u0026 build 编写基于 vue-demi 单文件组件模板库","archived":false,"fork":false,"pushed_at":"2025-02-26T03:59:56.000Z","size":453,"stargazers_count":35,"open_issues_count":0,"forks_count":11,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-03-19T03:53:13.565Z","etag":null,"topics":["vue-demi","vuejs"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ChuHoMan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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}},"created_at":"2022-03-20T17:05:13.000Z","updated_at":"2025-02-26T04:00:00.000Z","dependencies_parsed_at":"2025-02-26T04:26:25.670Z","dependency_job_id":"8a2e2852-ccab-401f-ab42-9a3449740347","html_url":"https://github.com/ChuHoMan/vue-demi-component-template","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/ChuHoMan%2Fvue-demi-component-template","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ChuHoMan%2Fvue-demi-component-template/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ChuHoMan%2Fvue-demi-component-template/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ChuHoMan%2Fvue-demi-component-template/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ChuHoMan","download_url":"https://codeload.github.com/ChuHoMan/vue-demi-component-template/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245269668,"owners_count":20587822,"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":["vue-demi","vuejs"],"created_at":"2024-10-29T01:05:37.871Z","updated_at":"2025-03-24T12:30:34.775Z","avatar_url":"https://github.com/ChuHoMan.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Vue-Demi + TS + Vite For SFC template\n\n\u003e Vue.js component template for Vue 2 and 2.7 and 3.\n\n\u003cp align='center'\u003e\n\u003cb\u003eEnglish\u003c/b\u003e | \u003ca href=\"https://github.com/ChuHoMan/vue-demi-component-template/blob/main/README.zh-CN.md\"\u003e简体中文\u003c/a\u003e\n\u003c/p\u003e\n\n## Features\n\n- Development environment for library mode in Vue 2.6/2.7/3\n- Testing/building environment for library mode in Vue 2/3\n- dts solution for library mode in Vue 2.7/3 (partial support for Vue 2.6)\n- Script to adapt package.json during release\n\n## Template Usage\n\nTo use this template, clone it down using:\n\n```bash\nnpx degit ChuHoMan/vue-demi-component-template my-component\n```\n\nAnd do a global replace of `vue-demi-component-template` and `VueDemiComponentTemplate` with your component library name.\n\n## Setup\n\nMake sure to install the dependencies:\n\n```bash\n# pnpm\npnpm install\n```\n\n\u003e ⚠️ Important:  If you are using pnpm 10.x, you need to add the following configuration in the package.json of the vue-demi-component-template project:\n\u003e ```json\n\u003e {\n\u003e   \"pnpm\": {\n\u003e     \"onlyBuiltDependencies\": [\"vue-demi-component-template\"]\n\u003e   }\n\u003e }\n\u003e ```\n\u003e This is because pnpm 10.x blocks postinstall scripts by default, while vue-demi-component-template relies on postinstall scripts to select the appropriate build artifacts for Vue version compatibility. For more details, see [pnpm/pnpm#8897](https://github.com/pnpm/pnpm/pull/8897).\n\n## Development Server\n\nStart the development server\n\n```bash\n# Vue 2.6.x\npnpm run dev:2\n# Vue 2.7.x\npnpm run dev:2.7\n# Vue 3\npnpm run dev:3\n```\n\n## How to use dist file？\n\n### From CDN or without a Bundler\n\n```html\n\u003c!DOCTYPE html\u003e\n\u003chtml lang=\"en\"\u003e\n  \u003chead\u003e\n    \u003cmeta charset=\"UTF-8\" /\u003e\n    \u003clink rel=\"icon\" href=\"/favicon.ico\" /\u003e\n    \u003cmeta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\" /\u003e\n    \u003ctitle\u003eVite App\u003c/title\u003e\n    \u003cscript src=\"https://unpkg.com/vue@3.2.47/dist/vue.global.prod.js\"\u003e\u003c/script\u003e\n    \u003c!-- Make sure your current directory has this umd asset --\u003e\n    \u003cscript src=\"/dist/v3/index.umd.js\"\u003e\u003c/script\u003e\n  \u003c/head\u003e\n  \u003cbody\u003e\n    \u003cdiv id=\"app\"\u003e\n        \u003cvue-demi-component-template\u003e\u003c/vue-demi-component-template\u003e\n    \u003c/div\u003e\n  \u003c/body\u003e\n  \u003cscript\u003e\n    const app = Vue.createApp({})\n    app.use(VueDemiTemplateComponent)\n    app.mount('#app')\n  \u003c/script\u003e\n\u003c/html\u003e\n```\n\n## Production\n\nBuild the library for production or publish:\n\n```bash\n# build all versions\npnpm run build\n```\n\n## License\n\nMade with 💙\n\nPublished under [MIT License](./LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchuhoman%2Fvue-demi-component-template","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchuhoman%2Fvue-demi-component-template","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchuhoman%2Fvue-demi-component-template/lists"}