Vue3 Pnpm Workspace screenshot

Vue3 Pnpm Workspace

Author Avatar Theme by Ghiscoding
Updated: 11 Jul 2022
29 Stars

Vue 3 pnpm workspace boilerplate for reusable Components & Composables across a multi-applications setup

Overview

The Vue 3 and pnpm workspace boilerplate is an excellent choice for developers looking to optimize their workflow while creating multiple applications. It focuses on leveraging pnpm workspaces to facilitate the sharing of reusable components and composables, fostering a collaborative environment for different teams. This setup adheres to the DRY (Don’t Repeat Yourself) principle, minimizing redundancy in code and allowing for efficient development.

With the ability to run applications both locally and with package publishing flexibility, this boilerplate offers a robust structure that can accommodate various project needs. Whether you prefer to keep your workspace self-contained or publish your components, this boilerplate simplifies the development and deployment process while maintaining high efficiency.

Features

  • pnpm Workspaces: Organize multiple Vue 3 applications under one workspace, making it easy to share components and composables across projects.
  • Vite Integration: Utilize Vite’s library mode to build components and composables as distributable packages, enhancing modular development.
  • TypeScript Support: Built-in TypeScript environment allows for type safety and improved code quality through the use of Composition API.
  • Auto-importing Components: Leverage unplugin-vue-components to automatically import Vue components, reducing boilerplate code.
  • ESLint with Prettier: Maintain code quality and consistency with ESLint and Prettier integration, featuring eslint-plugin-prettier to streamline the linting process.
  • Reusable Examples: Includes simple examples, like a MyButton component and useMouse composable, to help developers understand how to create and implement reusable code.
  • Dynamic Development: Take advantage of Vite’s build.watch feature, allowing for quick rebuilds during development without manual intervention.
  • Expandability: Easily add new components or directives by incorporating them into the pnpm workspace structure, providing flexibility as project requirements evolve.